1 // © 2016 and later: Unicode, Inc. and others.
2 // License & terms of use: http://www.unicode.org/copyright.html
4 *****************************************************************************************
5 * Copyright (C) 2010-2013, International Business Machines
6 * Corporation and others. All Rights Reserved.
7 *****************************************************************************************
13 #include "unicode/utypes.h"
15 #if !UCONFIG_NO_FORMATTING
17 #include "unicode/localpointer.h"
21 * \brief C API: The purpose of this API is to compute the gender of a list as a
22 * whole given the gender of each element.
50 typedef enum UGender UGender
;
53 * Opaque UGenderInfo object for use in C programs.
57 typedef struct UGenderInfo UGenderInfo
;
60 * Opens a new UGenderInfo object given locale.
61 * @param locale The locale for which the rules are desired.
62 * @param status UErrorCode pointer
63 * @return A UGenderInfo for the specified locale, or NULL if an error occurred.
66 U_STABLE
const UGenderInfo
* U_EXPORT2
67 ugender_getInstance(const char *locale
, UErrorCode
*status
);
71 * Given a list, returns the gender of the list as a whole.
72 * @param genderInfo pointer that ugender_getInstance returns.
73 * @param genders the gender of each element in the list.
74 * @param size the size of the list.
75 * @param status A pointer to a UErrorCode to receive any errors.
76 * @return The gender of the list.
79 U_STABLE UGender U_EXPORT2
80 ugender_getListGender(const UGenderInfo
* genderinfo
, const UGender
*genders
, int32_t size
, UErrorCode
*status
);
82 #endif /* #if !UCONFIG_NO_FORMATTING */