diff options
author | Eike Rathke <erack@redhat.com> | 2013-09-05 15:54:14 +0200 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2013-09-05 16:51:28 +0200 |
commit | e13fd395939ff037a38172a87366a84293df7e30 (patch) | |
tree | fe13b157c41b7e4bf14c83bfd84a644951f83984 /include | |
parent | c2b18aa7743ffb0b3e229deafb2740322d7560b3 (diff) |
getFallbackStrings() with bIncludeFullBcp47 parameter
so the various places that check the full tag first do not have to get
it just to delete it again.
Change-Id: Ib4e3cf1b16988464db875f1b6ac5cf4a0ab60fe5
Diffstat (limited to 'include')
-rw-r--r-- | include/i18nlangtag/languagetag.hxx | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/include/i18nlangtag/languagetag.hxx b/include/i18nlangtag/languagetag.hxx index 9b922f7e05ce..06baf8d27993 100644 --- a/include/i18nlangtag/languagetag.hxx +++ b/include/i18nlangtag/languagetag.hxx @@ -267,6 +267,17 @@ public: lll-CC lll + If the tag includes variants the order is: + full BCP 47 tag, same as getBcp47() + lll-Ssss-CC-vvvvvvvv + lll-Ssss-vvvvvvvv + lll-Ssss-CC + lll-Ssss + lll-CC-vvvvvvvv + lll-vvvvvvvv + lll-CC + lll + Only strings that differ from a higher order are included, for example if there is no script the elements will be bcp47, lll-CC, lll; if the bcp47 string is identical to lll-CC then only lll-CC, lll. @@ -274,8 +285,14 @@ public: Note that lll is only ISO 639-1/2 alpha code and CC is only ISO 3166 alpha code. If the region can not be expressed as ISO 3166 then no -CC tags are included. + + @param bIncludeFullBcp47 + If TRUE, the full BCP 47 tag is included as first element. + If FALSE, the full tag is not included; used if the caller + obtains the fallbacks only if the full tag did not lead to a + match, so subsequent tries need not to include it again. */ - ::std::vector< OUString > getFallbackStrings() const; + ::std::vector< OUString > getFallbackStrings( bool bIncludeFullBcp47 ) const; /** @short Search for an equal or at least for a similar locale in a list |