@@ -477,7 +477,7 @@ Locale::clone() const {
477477bool
478478Locale::operator ==( const Locale& other) const
479479{
480- return ( uprv_strcmp (other.fullName , fullName) == 0 ) ;
480+ return uprv_strcmp (other.getName (), getName ()) == 0 ;
481481}
482482
483483namespace {
@@ -1965,7 +1965,7 @@ Locale& Locale::init(StringPiece localeID, UBool canonicalize)
19651965 }
19661966
19671967 if (canonicalize) {
1968- if (!isKnownCanonicalizedLocale (fullName , err)) {
1968+ if (!isKnownCanonicalizedLocale (getName () , err)) {
19691969 CharString replaced;
19701970 // Not sure it is already canonicalized
19711971 if (canonicalizeLocale (*this , replaced, err)) {
@@ -2030,7 +2030,7 @@ Locale::initBaseName(UErrorCode &status) {
20302030int32_t
20312031Locale::hashCode () const
20322032{
2033- return ustr_hashCharsN (fullName , static_cast <int32_t >(uprv_strlen (fullName )));
2033+ return ustr_hashCharsN (getName () , static_cast <int32_t >(uprv_strlen (getName () )));
20342034}
20352035
20362036void
@@ -2088,7 +2088,7 @@ Locale::addLikelySubtags(UErrorCode& status) {
20882088 return ;
20892089 }
20902090
2091- CharString maximizedLocaleID = ulocimp_addLikelySubtags (fullName , status);
2091+ CharString maximizedLocaleID = ulocimp_addLikelySubtags (getName () , status);
20922092
20932093 if (U_FAILURE (status)) {
20942094 return ;
@@ -2110,7 +2110,7 @@ Locale::minimizeSubtags(bool favorScript, UErrorCode& status) {
21102110 return ;
21112111 }
21122112
2113- CharString minimizedLocaleID = ulocimp_minimizeSubtags (fullName , favorScript, status);
2113+ CharString minimizedLocaleID = ulocimp_minimizeSubtags (getName () , favorScript, status);
21142114
21152115 if (U_FAILURE (status)) {
21162116 return ;
@@ -2131,7 +2131,7 @@ Locale::canonicalize(UErrorCode& status) {
21312131 status = U_ILLEGAL_ARGUMENT_ERROR;
21322132 return ;
21332133 }
2134- CharString uncanonicalized (fullName , status);
2134+ CharString uncanonicalized (getName () , status);
21352135 if (U_FAILURE (status)) {
21362136 return ;
21372137 }
@@ -2196,7 +2196,7 @@ Locale::toLanguageTag(ByteSink& sink, UErrorCode& status) const
21962196 return ;
21972197 }
21982198
2199- ulocimp_toLanguageTag (fullName , sink, /* strict=*/ false , status);
2199+ ulocimp_toLanguageTag (getName () , sink, /* strict=*/ false , status);
22002200}
22012201
22022202Locale U_EXPORT2
@@ -2229,14 +2229,14 @@ Locale::createCanonical(const char* name) {
22292229const char *
22302230Locale::getISO3Language () const
22312231{
2232- return uloc_getISO3Language (fullName );
2232+ return uloc_getISO3Language (getName () );
22332233}
22342234
22352235
22362236const char *
22372237Locale::getISO3Country () const
22382238{
2239- return uloc_getISO3Country (fullName );
2239+ return uloc_getISO3Country (getName () );
22402240}
22412241
22422242/* *
@@ -2249,7 +2249,7 @@ Locale::getISO3Country() const
22492249uint32_t
22502250Locale::getLCID () const
22512251{
2252- return uloc_getLCID (fullName );
2252+ return uloc_getLCID (getName () );
22532253}
22542254
22552255const char * const * U_EXPORT2 Locale::getISOCountries ()
@@ -2556,8 +2556,8 @@ Locale::createKeywords(UErrorCode &status) const
25562556 return result;
25572557 }
25582558
2559- const char * variantStart = uprv_strchr (fullName , ' @' );
2560- const char * assignment = uprv_strchr (fullName , ' =' );
2559+ const char * variantStart = uprv_strchr (getName () , ' @' );
2560+ const char * assignment = uprv_strchr (getName () , ' =' );
25612561 if (variantStart) {
25622562 if (assignment > variantStart) {
25632563 CharString keywords = ulocimp_getKeywords (variantStart + 1 , ' @' , false , status);
@@ -2583,8 +2583,8 @@ Locale::createUnicodeKeywords(UErrorCode &status) const
25832583 return result;
25842584 }
25852585
2586- const char * variantStart = uprv_strchr (fullName , ' @' );
2587- const char * assignment = uprv_strchr (fullName , ' =' );
2586+ const char * variantStart = uprv_strchr (getName () , ' @' );
2587+ const char * assignment = uprv_strchr (getName () , ' =' );
25882588 if (variantStart) {
25892589 if (assignment > variantStart) {
25902590 CharString keywords = ulocimp_getKeywords (variantStart + 1 , ' @' , false , status);
@@ -2604,7 +2604,7 @@ Locale::createUnicodeKeywords(UErrorCode &status) const
26042604int32_t
26052605Locale::getKeywordValue (const char * keywordName, char *buffer, int32_t bufLen, UErrorCode &status) const
26062606{
2607- return uloc_getKeywordValue (fullName , keywordName, buffer, bufLen, &status);
2607+ return uloc_getKeywordValue (getName () , keywordName, buffer, bufLen, &status);
26082608}
26092609
26102610void
@@ -2618,7 +2618,7 @@ Locale::getKeywordValue(StringPiece keywordName, ByteSink& sink, UErrorCode& sta
26182618 return ;
26192619 }
26202620
2621- ulocimp_getKeywordValue (fullName , keywordName, sink, status);
2621+ ulocimp_getKeywordValue (getName () , keywordName, sink, status);
26222622}
26232623
26242624void
@@ -2664,7 +2664,7 @@ Locale::setKeywordValue(StringPiece keywordName,
26642664 status = U_ZERO_ERROR;
26652665 }
26662666
2667- int32_t length = static_cast <int32_t >(uprv_strlen (fullName ));
2667+ int32_t length = static_cast <int32_t >(uprv_strlen (getName () ));
26682668 int32_t capacity = fullName == fullNameBuffer ? ULOC_FULLNAME_CAPACITY : length + 1 ;
26692669
26702670 const char * start = locale_getKeywordsStart (fullName);
0 commit comments