1*912701f9SAndroid Build Coastguard Worker## Unicode Technical Standard #35 2*912701f9SAndroid Build Coastguard Worker 3*912701f9SAndroid Build Coastguard Worker# Unicode Locale Data Markup Language (LDML)<br/>Part 8: Person Names 4*912701f9SAndroid Build Coastguard Worker 5*912701f9SAndroid Build Coastguard Worker|Version|45 | 6*912701f9SAndroid Build Coastguard Worker|-------|------------------------| 7*912701f9SAndroid Build Coastguard Worker|Editors|Mark Davis, Peter Edberg, Rich Gillam, Alex Kolisnychenko, Mike McKenna and [other CLDR committee members](tr35.md#Acknowledgments)| 8*912701f9SAndroid Build Coastguard Worker 9*912701f9SAndroid Build Coastguard WorkerFor the full header, summary, and status, see [Part 1: Core](tr35.md). 10*912701f9SAndroid Build Coastguard Worker 11*912701f9SAndroid Build Coastguard Worker### _Summary_ 12*912701f9SAndroid Build Coastguard Worker 13*912701f9SAndroid Build Coastguard WorkerThis document describes parts of an XML format (_vocabulary_) for the exchange of structured locale data. This format is used in the [Unicode Common Locale Data Repository](https://www.unicode.org/cldr/). 14*912701f9SAndroid Build Coastguard Worker 15*912701f9SAndroid Build Coastguard WorkerThis is a partial document, describing only those parts of the LDML that are relevant for person names (name structure, formats, sorting). For the other parts of the LDML see the [main LDML document](tr35.md) and the links above. 16*912701f9SAndroid Build Coastguard Worker 17*912701f9SAndroid Build Coastguard Worker### _Status_ 18*912701f9SAndroid Build Coastguard Worker 19*912701f9SAndroid Build Coastguard Worker<!-- _This is a draft document which may be updated, replaced, or superseded by other documents at any time. 20*912701f9SAndroid Build Coastguard WorkerPublication does not imply endorsement by the Unicode Consortium. 21*912701f9SAndroid Build Coastguard WorkerThis is not a stable document; it is inappropriate to cite this document as other than a work in progress._ --> 22*912701f9SAndroid Build Coastguard Worker 23*912701f9SAndroid Build Coastguard Worker_This document has been reviewed by Unicode members and other interested parties, and has been approved for publication by the Unicode Consortium. 24*912701f9SAndroid Build Coastguard WorkerThis is a stable document and may be used as reference material or cited as a normative reference by other specifications._ 25*912701f9SAndroid Build Coastguard Worker 26*912701f9SAndroid Build Coastguard Worker> _**A Unicode Technical Standard (UTS)** is an independent specification. Conformance to the Unicode Standard does not imply conformance to any UTS._ 27*912701f9SAndroid Build Coastguard Worker 28*912701f9SAndroid Build Coastguard Worker_Please submit corrigenda and other comments with the CLDR bug reporting form [[Bugs](tr35.md#Bugs)]. Related information that is useful in understanding this document is found in the [References](tr35.md#References). For the latest version of the Unicode Standard see [[Unicode](tr35.md#Unicode)]. For a list of current Unicode Technical Reports see [[Reports](tr35.md#Reports)]. For more information about versions of the Unicode Standard, see [[Versions](tr35.md#Versions)]._ 29*912701f9SAndroid Build Coastguard Worker 30*912701f9SAndroid Build Coastguard Worker## Parts 31*912701f9SAndroid Build Coastguard Worker 32*912701f9SAndroid Build Coastguard WorkerThe LDML specification is divided into the following parts: 33*912701f9SAndroid Build Coastguard Worker 34*912701f9SAndroid Build Coastguard Worker* Part 1: [Core](tr35.md#Contents) (languages, locales, basic structure) 35*912701f9SAndroid Build Coastguard Worker* Part 2: [General](tr35-general.md#Contents) (display names & transforms, etc.) 36*912701f9SAndroid Build Coastguard Worker* Part 3: [Numbers](tr35-numbers.md#Contents) (number & currency formatting) 37*912701f9SAndroid Build Coastguard Worker* Part 4: [Dates](tr35-dates.md#Contents) (date, time, time zone formatting) 38*912701f9SAndroid Build Coastguard Worker* Part 5: [Collation](tr35-collation.md#Contents) (sorting, searching, grouping) 39*912701f9SAndroid Build Coastguard Worker* Part 6: [Supplemental](tr35-info.md#Contents) (supplemental data) 40*912701f9SAndroid Build Coastguard Worker* Part 7: [Keyboards](tr35-keyboards.md#Contents) (keyboard mappings) 41*912701f9SAndroid Build Coastguard Worker* Part 8: [Person Names](tr35-personNames.md#Contents) (person names) 42*912701f9SAndroid Build Coastguard Worker* Part 9: [MessageFormat](tr35-messageFormat.md#Contents) (message format) 43*912701f9SAndroid Build Coastguard Worker 44*912701f9SAndroid Build Coastguard Worker## <a name="Contents">Contents of Part 8, Person Names</a> 45*912701f9SAndroid Build Coastguard Worker 46*912701f9SAndroid Build Coastguard Worker* [CLDR Person Names](#cldr-person-names) 47*912701f9SAndroid Build Coastguard Worker * [Introduction](#introduction) 48*912701f9SAndroid Build Coastguard Worker * [Not in scope](#not-in-scope) 49*912701f9SAndroid Build Coastguard Worker * [API Implementation](#api-implementation) 50*912701f9SAndroid Build Coastguard Worker * [Person Name Formatting Overview](#person-name-formatting-overview) 51*912701f9SAndroid Build Coastguard Worker * [Example Usage](#example-usage) 52*912701f9SAndroid Build Coastguard Worker* [XML Structure](#xml-structure) 53*912701f9SAndroid Build Coastguard Worker * [personNames Element](#personnames-element) 54*912701f9SAndroid Build Coastguard Worker * [personName Element](#personname-element) 55*912701f9SAndroid Build Coastguard Worker * [nameOrderLocales Element](#nameorderlocales-element) 56*912701f9SAndroid Build Coastguard Worker * [parameterDefault Element](#parameterdefault-element) 57*912701f9SAndroid Build Coastguard Worker * [foreignSpaceReplacement Element](#foreignspacereplacement-element) 58*912701f9SAndroid Build Coastguard Worker * [nativeSpaceReplacement Element](#nativespacereplacement-element) 59*912701f9SAndroid Build Coastguard Worker * [initialPattern Element](#initialpattern-element) 60*912701f9SAndroid Build Coastguard Worker * [Syntax](#syntax) 61*912701f9SAndroid Build Coastguard Worker* [Person Name Object](#person-name-object) 62*912701f9SAndroid Build Coastguard Worker* [Person Name Attributes](#person-name-attributes) 63*912701f9SAndroid Build Coastguard Worker * [order](#order) 64*912701f9SAndroid Build Coastguard Worker * [length](#length) 65*912701f9SAndroid Build Coastguard Worker * [usage](#usage) 66*912701f9SAndroid Build Coastguard Worker * [formality](#formality) 67*912701f9SAndroid Build Coastguard Worker* [namePattern Syntax](#namepattern-syntax) 68*912701f9SAndroid Build Coastguard Worker * [Fields](#fields) 69*912701f9SAndroid Build Coastguard Worker * [Modifiers](#modifiers) 70*912701f9SAndroid Build Coastguard Worker * [Grammatical Modifiers for Names](#grammatical-modifiers-for-names) 71*912701f9SAndroid Build Coastguard Worker * [Future Modifiers](#future-modifiers) 72*912701f9SAndroid Build Coastguard Worker* [Formatting Process](#formatting-process) 73*912701f9SAndroid Build Coastguard Worker * [Derive the name locale](#derive-the-name-locale) 74*912701f9SAndroid Build Coastguard Worker * [Derive the formatting locale](#derive-the-formatting-locale) 75*912701f9SAndroid Build Coastguard Worker * [Switch the formatting locale if necessary](#switch-the-formatting-locale-if-necessary) 76*912701f9SAndroid Build Coastguard Worker * [Derive the name order](#derive-the-name-order) 77*912701f9SAndroid Build Coastguard Worker * [Choose a personName element](#choose-a-personname-element) 78*912701f9SAndroid Build Coastguard Worker * [Choose a namePattern](#choose-a-namepattern) 79*912701f9SAndroid Build Coastguard Worker * [Access PersonName object](#access-personname-object) 80*912701f9SAndroid Build Coastguard Worker * [Handle missing surname](#handle-missing-surname) 81*912701f9SAndroid Build Coastguard Worker * [Handle core and prefix](#handle-core-and-prefix) 82*912701f9SAndroid Build Coastguard Worker * [Derive initials](#derive-initials) 83*912701f9SAndroid Build Coastguard Worker * [Process a namePattern](#process-a-namepattern) 84*912701f9SAndroid Build Coastguard Worker * [Handling foreign names](#handling-foreign-names) 85*912701f9SAndroid Build Coastguard Worker * [Setting the spaceReplacement](#setting-the-spacereplacement) 86*912701f9SAndroid Build Coastguard Worker * [Examples of space replacement](#examples-of-space-replacement) 87*912701f9SAndroid Build Coastguard Worker * [Formatting examples](#formatting-examples) 88*912701f9SAndroid Build Coastguard Worker* [Sample Name](#sample-name) 89*912701f9SAndroid Build Coastguard Worker * [Syntax](#syntax) 90*912701f9SAndroid Build Coastguard Worker * [Expected values](#expected-values) 91*912701f9SAndroid Build Coastguard Worker* [PersonName Data Interface Examples](#personname-data-interface-examples) 92*912701f9SAndroid Build Coastguard Worker * [Example 1](#example-1) 93*912701f9SAndroid Build Coastguard Worker * [Example 2](#example-2) 94*912701f9SAndroid Build Coastguard Worker 95*912701f9SAndroid Build Coastguard Worker## CLDR Person Names 96*912701f9SAndroid Build Coastguard Worker 97*912701f9SAndroid Build Coastguard Worker### Introduction 98*912701f9SAndroid Build Coastguard Worker 99*912701f9SAndroid Build Coastguard WorkerCLDR provides formatting for person names, such as John Smith or 宮崎駿. These use patterns to show how a name object (for example, from a database) should be formatted for a particular locale. Name data has fields for the parts of people’s names, such as a **given** field with a value of “Maria”, and a **surname** field value of “Schmidt”. 100*912701f9SAndroid Build Coastguard Worker 101*912701f9SAndroid Build Coastguard WorkerThere is a wide variety in the way that people’s names appear in different languages. 102*912701f9SAndroid Build Coastguard Worker 103*912701f9SAndroid Build Coastguard Worker* People may have a different number of names, depending on their culture—they might have only one name (“Zendaya”), two (“Albert Einstein”), or three or more. 104*912701f9SAndroid Build Coastguard Worker* People may have multiple words in a particular name field, eg “Mary Beth” as a given name, or “van Berg” as a surname. 105*912701f9SAndroid Build Coastguard Worker* Some languages, such as Spanish, have two surnames (where each can be composed of multiple words). 106*912701f9SAndroid Build Coastguard Worker* The ordering of name fields can be different across languages, as well as the spacing (or lack thereof) and punctuation. 107*912701f9SAndroid Build Coastguard Worker* Name formatting needs to be adapted to different circumstances, such as a need to be presented shorter or longer; formal or informal context; or when talking about someone, or talking to someone, or as a monogram (JFK). 108*912701f9SAndroid Build Coastguard Worker 109*912701f9SAndroid Build Coastguard WorkerThis document provides the [LDML](tr35.md) specification for formatting of personal names, using data, structure, and examples. 110*912701f9SAndroid Build Coastguard Worker 111*912701f9SAndroid Build Coastguard WorkerThe CLDR functionality is targeted at formatting names for typical usage on computers (e.g. contact names, automated greetings, etc.), rather than being designed for special circumstances or protocol, such addressing royalty. However, the structure may be enhanced in the future when it becomes clear that additional features are needed for some languages. 112*912701f9SAndroid Build Coastguard Worker 113*912701f9SAndroid Build Coastguard WorkerThis addition to CLDR is based on review of current standards and practices that exist in LDAP, OECD, S42, hCard, HTML and various other international standards and commercial implementations. 114*912701f9SAndroid Build Coastguard Worker 115*912701f9SAndroid Build Coastguard WorkerAdditions to those structures were made to accommodate known issues in large population groups, such as mononyms in Indonesia, patronymic and matronymic naming structure in Iceland and India, the need for a second surname in Spanish-speaking regions and the common case of chains of patronymic names in Arabic-speaking locales. The formatting patterns allow for specifying different “input parameters” to account for different contexts. 116*912701f9SAndroid Build Coastguard Worker 117*912701f9SAndroid Build Coastguard Worker#### Not in scope 118*912701f9SAndroid Build Coastguard Worker 119*912701f9SAndroid Build Coastguard WorkerThe following features are currently out of scope for Person Names formating: 120*912701f9SAndroid Build Coastguard Worker 121*912701f9SAndroid Build Coastguard Worker* Grammatical inflection of formatted names. 122*912701f9SAndroid Build Coastguard Worker* Context-specific cultural aspects, such as when to use “-san” vs “-sama” when addressing a Japanese person. 123*912701f9SAndroid Build Coastguard Worker* Providing locale-specific lists of titles, generation terms, and credentials for use in pull-down menus or validation (Mr, Ms., Mx., Dr., Jr., M.D., etc.). 124*912701f9SAndroid Build Coastguard Worker* Validation of input, such as which fields are required, and what characters are allowed. 125*912701f9SAndroid Build Coastguard Worker* Combining alternative names, such as multicultural names in Hong Kong "[Jackie Chan Kong-Sang](https://en.wikipedia.org/wiki/Jackie_Chan)”, or ‘Dwayne “The Rock” Johnson’. 126*912701f9SAndroid Build Coastguard Worker* More than two levels of formality for names. 127*912701f9SAndroid Build Coastguard Worker* Parsing of names: 128*912701f9SAndroid Build Coastguard Worker * Parsing of name strings into specific name parts such as given and given2. A name like "Mary Beth Estrella" could conceivably be any of the following. 129*912701f9SAndroid Build Coastguard Worker 130*912701f9SAndroid Build Coastguard Worker | given | given2 | surname | surname2 | 131*912701f9SAndroid Build Coastguard Worker | --------- | --------- | ------------- | -------- | 132*912701f9SAndroid Build Coastguard Worker | Mary | Beth | Estrella | | 133*912701f9SAndroid Build Coastguard Worker | Mary Beth | | Estrella | | 134*912701f9SAndroid Build Coastguard Worker | Mary | | Beth Estrella | | 135*912701f9SAndroid Build Coastguard Worker | Mary | | Beth | Estrella | 136*912701f9SAndroid Build Coastguard Worker 137*912701f9SAndroid Build Coastguard Worker * Parsing out the other components of a name in a string, such as surname prefixes ([Tussenvoegsel](https://en.wikipedia.org/wiki/Tussenvoegsel) in Dutch). 138*912701f9SAndroid Build Coastguard Worker 139*912701f9SAndroid Build Coastguard Worker### API Implementation 140*912701f9SAndroid Build Coastguard Worker 141*912701f9SAndroid Build Coastguard WorkerIn addition to the settings in this document, it is recommended that implementations provide some additional features in their APIs to allow more control for clients, notably: 142*912701f9SAndroid Build Coastguard Worker 143*912701f9SAndroid Build Coastguard Worker1. forceGivenFirst — no matter what the values are in nameOrderLocales or in the NameObject, display the name as givenFirst. 144*912701f9SAndroid Build Coastguard Worker2. forceSurnameFirst — no matter what the values are in nameOrderLocales or in the NameObject, display the name as surnameFirst. 145*912701f9SAndroid Build Coastguard Worker3. forceNativeOrdering — no matter what the values are in nameOrderLocales or in the NameObject, display the name with the same ordering as the native locale. 146*912701f9SAndroid Build Coastguard Worker4. surnameFirstAllCaps — display the surname and surname2 fields in all caps **if** not using native order. Thus where the foreign name ordering is surnameFirst, the name {given=Shinzo, surname=Abe} would display as “ABE Shinzo”. 147*912701f9SAndroid Build Coastguard Worker 148*912701f9SAndroid Build Coastguard Worker### Person Name Formatting Overview 149*912701f9SAndroid Build Coastguard Worker 150*912701f9SAndroid Build Coastguard WorkerLogically, the model used for applying the CLDR data is the following: 151*912701f9SAndroid Build Coastguard Worker 152*912701f9SAndroid Build Coastguard Worker 153*912701f9SAndroid Build Coastguard Worker 154*912701f9SAndroid Build Coastguard WorkerConceptually, CLDR person name formatting depends on data supplied by a PersonName Data Interface. That could be a very thin interface that simply accesses a database record, or it could be a more sophisticated interface that can modify the raw data before presenting it to be formatted. For example, based on the formatting locale a PersonName data interface could transliterate names that are in another script, or supply equivalent titles in different languages. 155*912701f9SAndroid Build Coastguard Worker 156*912701f9SAndroid Build Coastguard WorkerThe specification below will talk about a “PersonName object” as an entity that is logically accessed via such an interface. If multiple formatted names are needed, such as in different scripts or with alternate names, or pronunciations (eg kana), the presumption is that those are logically separate PersonName objects. See [[Person Name Object](#person-name-object)]. 157*912701f9SAndroid Build Coastguard Worker 158*912701f9SAndroid Build Coastguard WorkerThe following summarizes the name data supplied via the PersonName Data Interface: 159*912701f9SAndroid Build Coastguard Worker 160*912701f9SAndroid Build Coastguard Worker* Name data is composed of one or more name parts, which are categorized in this standard as 161*912701f9SAndroid Build Coastguard Worker * _title_ - a string that represents one or more honorifics or titles, such as “Mr.”, or “Herr Doctor”. 162*912701f9SAndroid Build Coastguard Worker * _given_ - usually a name given to someone that is not passed to a person by way of parentage 163*912701f9SAndroid Build Coastguard Worker * _given2_ - name or names that may appear between the first given name string and the surname. In the West, this may be a middle name, in Slavic regions it may be a patronymic name, and in parts of the Middle East, it may be the _nasab (نسب)_ or series of patronymics. 164*912701f9SAndroid Build Coastguard Worker * _surname_ - usually the family name passed to a person that indicates their family, tribe, or community. In most Western languages, this is known as the last name. 165*912701f9SAndroid Build Coastguard Worker * _surname2_ - in some cultures, both the parent’s surnames are used and need to be handled separately for formatting in different contexts. 166*912701f9SAndroid Build Coastguard Worker * _generation_ - a string that represents a generation marker, such as “Jr.” or “III”. 167*912701f9SAndroid Build Coastguard Worker * _credentials_ - a string that represents one or more credentials or accreditations, such as “M.D.”, or “MBA”. 168*912701f9SAndroid Build Coastguard Worker * _See the section on [[Fields](#fields)] for more details._ 169*912701f9SAndroid Build Coastguard Worker* Name data may have additional attributes that this specification accommodates. 170*912701f9SAndroid Build Coastguard Worker * _-informal_ - A name may have a formal and an informal presentation form, for example “Bob” vs “Robert” or “Са́ша” vs “Алекса́ндра”. This is accomplished by using the simple construct _given-informal_. 171*912701f9SAndroid Build Coastguard Worker * _-prefix_ and _-core_ - In some languages the surname may have a prefix that needs to be treated differently, for example “van den Berg”. The data can refer to “van den” as _surname-prefix_ and “Berg” with _surname-core_ and the PersonNames formatters will format them correctly in Dutch and many other languages. 172*912701f9SAndroid Build Coastguard Worker * _See the section on [[Modifiers](#modifiers)] for more details._ 173*912701f9SAndroid Build Coastguard Worker 174*912701f9SAndroid Build Coastguard WorkerTo format a name correctly, the correct context needs to be known. The context is composed of: 175*912701f9SAndroid Build Coastguard Worker 176*912701f9SAndroid Build Coastguard Worker* **The formatting locale.** This is used to choose the primary set of patterns to format name data. 177*912701f9SAndroid Build Coastguard Worker* **The name locale.** If the name data comes from a locale different from the formatting locale, it may need to be handled differently. If the name locale is not known, an inferred name locale is derived from the information in the name and the formatting locale. 178*912701f9SAndroid Build Coastguard Worker* **Input parameters.** 179*912701f9SAndroid Build Coastguard Worker * **_order_** - indicates whether the given name comes first or the surname. This is normally specified in the CLDR data for the locale. This feature is also used for the sorting format. 180*912701f9SAndroid Build Coastguard Worker * **_length_** - used to select patterns for common short, medium, and long formatted names. 181*912701f9SAndroid Build Coastguard Worker * **_usage_** - this is used to select the correct pattern to format a name when a program is _addressing_ or talking to a person or it is _referring_ to or talking about another person. 182*912701f9SAndroid Build Coastguard Worker * **_formality_** - This is used to select the formal or informal formatting of a name. 183*912701f9SAndroid Build Coastguard Worker * _See [[Person Name Attributes](#person-name-attributes)] for more details._ 184*912701f9SAndroid Build Coastguard Worker 185*912701f9SAndroid Build Coastguard Worker### Example Usage 186*912701f9SAndroid Build Coastguard Worker 187*912701f9SAndroid Build Coastguard WorkerAs an example, consider a person’s name that may contain: 188*912701f9SAndroid Build Coastguard Worker 189*912701f9SAndroid Build Coastguard Worker| `title` | `given` | `given2` | `surname` | `credentials` | 190*912701f9SAndroid Build Coastguard Worker| -------- | -------- | -------- | --------- | -------- | 191*912701f9SAndroid Build Coastguard Worker| | Robin | Finley | Wang | Ph.D. | 192*912701f9SAndroid Build Coastguard Worker 193*912701f9SAndroid Build Coastguard WorkerIf the selected personName data has the following formatting pattern: 194*912701f9SAndroid Build Coastguard Worker 195*912701f9SAndroid Build Coastguard Worker> `{title} {given} {given2-initial} {surname}, {credentials}` 196*912701f9SAndroid Build Coastguard Worker 197*912701f9SAndroid Build Coastguard WorkerThen the output is: 198*912701f9SAndroid Build Coastguard Worker 199*912701f9SAndroid Build Coastguard Worker> Robin F. Wang, Ph.D. 200*912701f9SAndroid Build Coastguard Worker 201*912701f9SAndroid Build Coastguard WorkerThe _title_ field is empty, so both it and the space that follows it in the formatting pattern are omitted from the output, the _given2_ field is formatted as an initial, and a preceding comma is placed before the _credentials_. 202*912701f9SAndroid Build Coastguard Worker 203*912701f9SAndroid Build Coastguard WorkerSections below specify the precise manner in which a pattern is selected, and how the pattern is modified for missing fields. 204*912701f9SAndroid Build Coastguard Worker 205*912701f9SAndroid Build Coastguard Worker## XML Structure 206*912701f9SAndroid Build Coastguard Worker 207*912701f9SAndroid Build Coastguard WorkerPerson name formatting data is stored as LDML with schema defined as follows. Each element has a brief description of the usage, but the exact algorithms for using these elements are provided in [Formatting Process](#formatting-process). 208*912701f9SAndroid Build Coastguard Worker 209*912701f9SAndroid Build Coastguard Worker 210*912701f9SAndroid Build Coastguard Worker### personNames Element 211*912701f9SAndroid Build Coastguard Worker 212*912701f9SAndroid Build Coastguard Worker```xml 213*912701f9SAndroid Build Coastguard Worker<!ELEMENT personNames ( nameOrderLocales*, parameterDefault*, nativeSpaceReplacement*, foreignSpaceReplacement*, initialPattern*, personName*, sampleName* ) > 214*912701f9SAndroid Build Coastguard Worker``` 215*912701f9SAndroid Build Coastguard Worker 216*912701f9SAndroid Build Coastguard WorkerThe LDML top-level `<personNames>` element contains information regarding the formatting of person names, and the formatting of person names in specific contexts for a specific locale. 217*912701f9SAndroid Build Coastguard Worker 218*912701f9SAndroid Build Coastguard Worker### personName Element 219*912701f9SAndroid Build Coastguard Worker 220*912701f9SAndroid Build Coastguard WorkerThe `<personName>` element contains the format patterns, or `<namePattern>` elements, for a specific context and is described in [[namePattern Syntax](#namepattern-syntax)] 221*912701f9SAndroid Build Coastguard Worker 222*912701f9SAndroid Build Coastguard WorkerThe `<namePattern>` syntax is described in [[Person Name Format Patterns](#formatting-process)]. 223*912701f9SAndroid Build Coastguard Worker 224*912701f9SAndroid Build Coastguard Worker```xml 225*912701f9SAndroid Build Coastguard Worker<!ELEMENT personName ( namePattern+ ) > 226*912701f9SAndroid Build Coastguard Worker<!ATTLIST personName order NMTOKEN #IMPLIED > 227*912701f9SAndroid Build Coastguard Worker``` 228*912701f9SAndroid Build Coastguard Worker 229*912701f9SAndroid Build Coastguard Worker* `NMTOKEN` is one of `( surnameFirst | givenFirst | sorting )` 230*912701f9SAndroid Build Coastguard Worker 231*912701f9SAndroid Build Coastguard Worker```xml 232*912701f9SAndroid Build Coastguard Worker<!ATTLIST personName length NMTOKEN #IMPLIED > 233*912701f9SAndroid Build Coastguard Worker``` 234*912701f9SAndroid Build Coastguard Worker 235*912701f9SAndroid Build Coastguard Worker* `NMTOKEN` is one of `( long | medium | short )` 236*912701f9SAndroid Build Coastguard Worker 237*912701f9SAndroid Build Coastguard Worker```xml 238*912701f9SAndroid Build Coastguard Worker<!ATTLIST personName usage NMTOKEN #IMPLIED > 239*912701f9SAndroid Build Coastguard Worker``` 240*912701f9SAndroid Build Coastguard Worker 241*912701f9SAndroid Build Coastguard Worker* `NMTOKEN` is one of `( addressing | referring | monogram )` 242*912701f9SAndroid Build Coastguard Worker 243*912701f9SAndroid Build Coastguard Worker```xml 244*912701f9SAndroid Build Coastguard Worker<!ATTLIST personName formality NMTOKEN #IMPLIED > 245*912701f9SAndroid Build Coastguard Worker``` 246*912701f9SAndroid Build Coastguard Worker 247*912701f9SAndroid Build Coastguard Worker* `NMTOKEN` is one of `( formal | informal )` 248*912701f9SAndroid Build Coastguard Worker 249*912701f9SAndroid Build Coastguard WorkerThe `<personName>` element has attributes of `order`, `length`, `usage`, and `formality`, and contains one or more `<namePattern>` elements. 250*912701f9SAndroid Build Coastguard Worker 251*912701f9SAndroid Build Coastguard WorkerA missing attribute matches all valid values for that attribute. For example, if `formality=...` is missing, it is equivalent to multiple lines, one for each possible `formality` attribute. 252*912701f9SAndroid Build Coastguard Worker 253*912701f9SAndroid Build Coastguard Worker```xml 254*912701f9SAndroid Build Coastguard Worker<!ELEMENT namePattern ( #PCDATA ) > 255*912701f9SAndroid Build Coastguard Worker``` 256*912701f9SAndroid Build Coastguard Worker 257*912701f9SAndroid Build Coastguard WorkerA `namePattern` contains a list of PersonName fields enclosed in curly braces, separated by literals, such as: 258*912701f9SAndroid Build Coastguard Worker 259*912701f9SAndroid Build Coastguard Worker> `<namePattern>{surname}, {given} {given2}</namePattern>` 260*912701f9SAndroid Build Coastguard Worker 261*912701f9SAndroid Build Coastguard Workerwhich produces output like _“Smith, Robert James”_. See [[namePattern Syntax](#namepattern-syntax)] for more details. 262*912701f9SAndroid Build Coastguard Worker 263*912701f9SAndroid Build Coastguard Worker### nameOrderLocales Element 264*912701f9SAndroid Build Coastguard Worker 265*912701f9SAndroid Build Coastguard WorkerThe `<nameOrderLocales>` element is optional, and contains information about selecting patterns based on the locale of a passed in PersonName object to determine the order of elements in a formatted name. For more information see [[NameOrder](#derive-the-name-order)]. It has a structure as follows: 266*912701f9SAndroid Build Coastguard Worker 267*912701f9SAndroid Build Coastguard Worker```xml 268*912701f9SAndroid Build Coastguard Worker<!ELEMENT nameOrderLocales `( #PCDATA )`> 269*912701f9SAndroid Build Coastguard Worker<!ATTLIST nameOrderLocales order ( givenFirst | surnameFirst ) #REQUIRED > 270*912701f9SAndroid Build Coastguard Worker``` 271*912701f9SAndroid Build Coastguard Worker 272*912701f9SAndroid Build Coastguard Worker* `#PCDATA `is a space delimited list of one or more [unicode_locale_id](tr35.md#unicode_locale_id)s. Normally each locale is limited to language, script, and region. The _und_ locale ID may only occur once, either in _surnameFirst_ or _givenFirst_, but not both, and matches all base locales not explicitly listed. 273*912701f9SAndroid Build Coastguard Worker 274*912701f9SAndroid Build Coastguard WorkerAn example from English may look like the following 275*912701f9SAndroid Build Coastguard Worker 276*912701f9SAndroid Build Coastguard Worker> `<nameOrderLocales order="givenFirst">und en</nameOrderLocales>`<br/> 277*912701f9SAndroid Build Coastguard Worker> `<nameOrderLocales order="surnameFirst">ko vi yue zh</nameOrderLocales>` 278*912701f9SAndroid Build Coastguard Worker 279*912701f9SAndroid Build Coastguard WorkerThis would tell the formatting code, when handling person name data from an English locale, to use patterns with the `givenFirst` order attribute for all data except name data from Korean, Vietnamese, Cantonese, and Chinese locales, where the `surnameFirst` patterns should be used. 280*912701f9SAndroid Build Coastguard Worker 281*912701f9SAndroid Build Coastguard Worker### parameterDefault Element 282*912701f9SAndroid Build Coastguard Worker```xml 283*912701f9SAndroid Build Coastguard Worker<!ELEMENT parameterDefault ( #PCDATA ) > 284*912701f9SAndroid Build Coastguard Worker<!ATTLIST parameterDefault parameter (length | formality) #REQUIRED > 285*912701f9SAndroid Build Coastguard Worker``` 286*912701f9SAndroid Build Coastguard WorkerMany clients of the person-names functionality don’t really care about formal versus informal; they just want whatever the “normal” formality level is for the user’s language. The same goes for the default length. 287*912701f9SAndroid Build Coastguard Worker 288*912701f9SAndroid Build Coastguard WorkerThis parameter provides that information, so that APIs can allow users to use default values for the formality and length. The exact form that this takes depends on the API conventions, of course. 289*912701f9SAndroid Build Coastguard Worker 290*912701f9SAndroid Build Coastguard Worker### foreignSpaceReplacement Element 291*912701f9SAndroid Build Coastguard Worker 292*912701f9SAndroid Build Coastguard WorkerThe `<foreignSpaceReplacement>` element is used to specify how spaces should be handled when the name language is **different from** the formatting language. It is used in languages that don't normally require spaces between words. For example, Japanese and Chinese have the value of a middle dot (‘·’ U+00B7 MIDDLE DOT or ‘・’ U+30FB KATAKANA MIDDLE DOT), so that it is used between words in a foreign name; most other languages have the value of SPACE. 293*912701f9SAndroid Build Coastguard Worker 294*912701f9SAndroid Build Coastguard Worker```xml 295*912701f9SAndroid Build Coastguard Worker<!ELEMENT foreignSpaceReplacement ( #PCDATA ) > 296*912701f9SAndroid Build Coastguard Worker<!ATTLIST foreignSpaceReplacement xml:space preserve #REQUIRED > 297*912701f9SAndroid Build Coastguard Worker``` 298*912701f9SAndroid Build Coastguard Worker 299*912701f9SAndroid Build Coastguard Worker* `xml:space` must be set to `'preserve'` so that actual spaces in the pattern are preserved. See [W3C XML White Space Handling](https://www.w3.org/TR/xml/#sec-white-space). 300*912701f9SAndroid Build Coastguard Worker* The `#PCDATA `is the character sequence used to replace spaces when postprocessing a pattern. 301*912701f9SAndroid Build Coastguard Worker 302*912701f9SAndroid Build Coastguard Worker### nativeSpaceReplacement Element 303*912701f9SAndroid Build Coastguard Worker 304*912701f9SAndroid Build Coastguard WorkerThe `<nativeSpaceReplacement>` element is used to specify how spaces should be handled when the name language is **the same as** the formatting language. It is used in languages that don't normally require spaces between words, but may use spaces within names. For example, Japanese and Chinese have the value of an empty string between words in a native name; most other languages have the value of SPACE. 305*912701f9SAndroid Build Coastguard Worker 306*912701f9SAndroid Build Coastguard Worker```xml 307*912701f9SAndroid Build Coastguard Worker<!ELEMENT nativeSpaceReplacement ( #PCDATA ) > 308*912701f9SAndroid Build Coastguard Worker<!ATTLIST nativeSpaceReplacement xml:space preserve #REQUIRED > 309*912701f9SAndroid Build Coastguard Worker``` 310*912701f9SAndroid Build Coastguard Worker 311*912701f9SAndroid Build Coastguard Worker* `xml:space` must be set to `'preserve'` so that actual spaces in the pattern are preserved. See [W3C XML White Space Handling](https://www.w3.org/TR/xml/#sec-white-space). 312*912701f9SAndroid Build Coastguard Worker* The `#PCDATA `is the character sequence used to replace spaces when postprocessing a pattern. 313*912701f9SAndroid Build Coastguard Worker 314*912701f9SAndroid Build Coastguard Worker### initialPattern Element 315*912701f9SAndroid Build Coastguard Worker 316*912701f9SAndroid Build Coastguard WorkerThe `<initialPattern>` element is used to specify how to format initials of name parts. 317*912701f9SAndroid Build Coastguard Worker 318*912701f9SAndroid Build Coastguard Worker**_initial_** is a pattern used to display a single initial in the locale, while **_initialSequence_** is a pattern used to “glue” together multiple initials for multiword fields, for example with the given name “Mary Beth” in English. 319*912701f9SAndroid Build Coastguard Worker 320*912701f9SAndroid Build Coastguard Worker#### Syntax 321*912701f9SAndroid Build Coastguard Worker 322*912701f9SAndroid Build Coastguard Worker```xml 323*912701f9SAndroid Build Coastguard Worker<!ELEMENT initialPattern ( #PCDATA ) > 324*912701f9SAndroid Build Coastguard Worker<!ATTLIST initialPattern type ( initial | initialSequence) #REQUIRED > 325*912701f9SAndroid Build Coastguard Worker``` 326*912701f9SAndroid Build Coastguard Worker 327*912701f9SAndroid Build Coastguard WorkerThe `type="initial"` is used to specify the pattern for how single initials are created, for example “Wolcott” => “W.” would have an entry of 328*912701f9SAndroid Build Coastguard Worker 329*912701f9SAndroid Build Coastguard Worker> `<initialPattern type="initial">{0}.</initialPattern>` 330*912701f9SAndroid Build Coastguard Worker 331*912701f9SAndroid Build Coastguard Worker`type="initialSequence`” is used to specify how a series of initials should appear, for example “Wolcott Janus” => “W. J.”, with spaces between each initial, would have a specifier of 332*912701f9SAndroid Build Coastguard Worker 333*912701f9SAndroid Build Coastguard Worker> `<initialPattern type="initialSequence">{0} {1}</initialPattern>` 334*912701f9SAndroid Build Coastguard Worker 335*912701f9SAndroid Build Coastguard Worker## Person Name Object 336*912701f9SAndroid Build Coastguard Worker 337*912701f9SAndroid Build Coastguard WorkerThe information that is to be formatted logically consists of a data object containing a number of fields. This data object is a construct for the purpose of formatting, and doesn’t represent the source of the name data. That is, the original source may contain more information. The PersonName object is merely a logical ‘transport’ of information to formatting; it may in actuality consist of, for example, an API that fetches fields from a database. 338*912701f9SAndroid Build Coastguard Worker 339*912701f9SAndroid Build Coastguard WorkerNote that an application might have more than one set of name data for a given person, such as data for both a legal name and a nickname or preferred name. Or the source data may contain two whole sets of name data for a person from an Eastern Slavic region, one in Cyrillic characters and one in Latin characters. Or it might contain phonetic data for a name (commonly used in Japan). The additional application-specific information in person’s names is out of scope for the CLDR Person Name formatting data. Thus a calling application may produce more than one PersonName object to format depending on the purpose. 340*912701f9SAndroid Build Coastguard Worker 341*912701f9SAndroid Build Coastguard WorkerFor illustration, the following is a sample PersonName object. 342*912701f9SAndroid Build Coastguard Worker 343*912701f9SAndroid Build Coastguard Worker| Field | Value | Comment | 344*912701f9SAndroid Build Coastguard Worker| ---------------- | ------------ | ------------------------------- | 345*912701f9SAndroid Build Coastguard Worker| `title` | “Dr.” | | 346*912701f9SAndroid Build Coastguard Worker| `given` | “William” | | 347*912701f9SAndroid Build Coastguard Worker| `given-informal` | “Bill” | example inclusion of "nickname" | 348*912701f9SAndroid Build Coastguard Worker| `given2` | “Torval” | | 349*912701f9SAndroid Build Coastguard Worker| `surname` | “Brown” | | 350*912701f9SAndroid Build Coastguard Worker| `nameLocale` | “und-US” | this is just for illustration | 351*912701f9SAndroid Build Coastguard Worker| `preferredOrder` | “givenFirst” | values are givenFirst and surnameFirst | 352*912701f9SAndroid Build Coastguard Worker 353*912701f9SAndroid Build Coastguard WorkerA PersonName object is logically composed of the fields above plus other possible variations. See [[Fields](#fields)]. There must be at least one field present: either a `given` or `surname` field. Other fields are optional, and some of them can be constructed from other fields if necessary. 354*912701f9SAndroid Build Coastguard Worker 355*912701f9SAndroid Build Coastguard WorkerA modifier is supplied, _-informal_, which can be used to indicate which data element to choose when formatting informal cases which might include nicknames or preferred names. For more details, see section on [_[Modifiers](#modifiers)_] in [namePattern Syntax](#namepattern-syntax) below. 356*912701f9SAndroid Build Coastguard Worker 357*912701f9SAndroid Build Coastguard Worker## Person Name Attributes 358*912701f9SAndroid Build Coastguard Worker 359*912701f9SAndroid Build Coastguard WorkerA person name pattern may have any of four attributes: order, length, usage, and formality. LDML specifies that all the values for these attributes are unique. For example, because length=long is valid, usage=long cannot also be valid. That allows the pattern labels to be simple, because the attribute names can be skipped. That is, 360*912701f9SAndroid Build Coastguard Worker 361*912701f9SAndroid Build Coastguard Worker> `{order=givenFirst, length=long, usage=referring, formality=formal}` 362*912701f9SAndroid Build Coastguard Worker 363*912701f9SAndroid Build Coastguard Workercan be abbreviated without loss of information as: 364*912701f9SAndroid Build Coastguard Worker 365*912701f9SAndroid Build Coastguard Worker> _givenFirst-long-referring-formal._ 366*912701f9SAndroid Build Coastguard Worker 367*912701f9SAndroid Build Coastguard WorkerEach of these attributes are described below using sample PersonName objects as examples. 368*912701f9SAndroid Build Coastguard Worker 369*912701f9SAndroid Build Coastguard Worker### order 370*912701f9SAndroid Build Coastguard Worker 371*912701f9SAndroid Build Coastguard WorkerThe order attribute is used for patterns with different orders of fields. The order=sorting patterns are chosen based on input parameters, while the choice between givenFirst and surnameFirst is based on features of the PersonName object to be formatted and the nameOrder element values. 372*912701f9SAndroid Build Coastguard Worker 373*912701f9SAndroid Build Coastguard Worker| Parameter | Description | 374*912701f9SAndroid Build Coastguard Worker| -------------- | -------------------------------------------- | 375*912701f9SAndroid Build Coastguard Worker| `givenFirst` | The given name precedes the surname. | 376*912701f9SAndroid Build Coastguard Worker| `surnameFirst` | The surname precedes the given name. | 377*912701f9SAndroid Build Coastguard Worker| `sorting` | Used to format names for a sorted list.<br/>example: “Brown, William” [medium, informal] | 378*912701f9SAndroid Build Coastguard Worker 379*912701f9SAndroid Build Coastguard WorkerFor example, when the display language is Japanese, it is customary to use _surnameFirst_ for names of people from Japan and Hungary, but use _givenFirst_ for names of people from the United States and France. Although the English pattern for sorting is distinct from the other patterns (except for unusual names), that is not necessarily the case in other languages. 380*912701f9SAndroid Build Coastguard Worker 381*912701f9SAndroid Build Coastguard Worker### length 382*912701f9SAndroid Build Coastguard Worker 383*912701f9SAndroid Build Coastguard WorkerThe `length` attribute specifies the relative length of a formatted name depending on context. For example, a `long` formal name in English might include title, given, given2, surname plus generation and credentials; whereas a `short` informal name may only be the given name. 384*912701f9SAndroid Build Coastguard Worker 385*912701f9SAndroid Build Coastguard WorkerNote that the formats may be the same for different lengths depending on the formality, usage, and cultural conventions for the locale. For example, medium and short may be the same for a particular context. 386*912701f9SAndroid Build Coastguard Worker 387*912701f9SAndroid Build Coastguard Worker| Parameter | Description | 388*912701f9SAndroid Build Coastguard Worker| --------- | ----------- | 389*912701f9SAndroid Build Coastguard Worker| `long` | A `long` length would usually include all parts needed for a legal name or identification.<br/>Example: `usage="referring", formality="formal"`<br/>_“Mr. Robert John Smith, PhD”_ | 390*912701f9SAndroid Build Coastguard Worker| `medium` | A `medium` length is between long and short.<br/>Example: `usage="referring", formality="formal"`<br/>_“Robert Smith”_ | 391*912701f9SAndroid Build Coastguard Worker| `short` | A `short` length uses a minimum set of names.<br/>Example: `usage="referring", formality="formal"`<br/>_“Mr. Smith”_ | 392*912701f9SAndroid Build Coastguard Worker 393*912701f9SAndroid Build Coastguard Worker### usage 394*912701f9SAndroid Build Coastguard Worker 395*912701f9SAndroid Build Coastguard WorkerThe usage indicates if the formatted name is being used to address someone, refer to someone, or present their name in an abbreviated form. 396*912701f9SAndroid Build Coastguard Worker 397*912701f9SAndroid Build Coastguard WorkerThe pattern for `usage="referring"` may be the same as the pattern for `usage="addressing"`. 398*912701f9SAndroid Build Coastguard Worker 399*912701f9SAndroid Build Coastguard Worker| Parameter | Description | 400*912701f9SAndroid Build Coastguard Worker| ------------ | ----------- | 401*912701f9SAndroid Build Coastguard Worker| `addressing` | Used when speaking “to” a person, or “vocative” case. This may also have an effect on the formality.<br/>example: “Welcome, **Robert**” | 402*912701f9SAndroid Build Coastguard Worker| `referring` | Used when speaking “about” a person, or “nominative” case.<br/>example: “**Robert Smith** joined your group” | 403*912701f9SAndroid Build Coastguard Worker| `monogram` | The `monogram` usage is for a specific abbreviated form for computer UI.<br/>Example: a monogram for Robert James Smith may be **RS** or **RJS**.| 404*912701f9SAndroid Build Coastguard Worker 405*912701f9SAndroid Build Coastguard WorkerSlavic languages provide a good example of `addressing` vs `referring`. An example _uk-Cyrl_ PersonName object: 406*912701f9SAndroid Build Coastguard Worker 407*912701f9SAndroid Build Coastguard Worker| Field | Value | Comment | 408*912701f9SAndroid Build Coastguard Worker| ---------------- | ------------ | ------------------------------- | 409*912701f9SAndroid Build Coastguard Worker| `title` | “г-н” | “Mr.” | 410*912701f9SAndroid Build Coastguard Worker| `given` | “Иван” | “Ivan” | 411*912701f9SAndroid Build Coastguard Worker| `given2` | “Петрович” | “Petrovich” | 412*912701f9SAndroid Build Coastguard Worker| `surname` | “Васильев” | “Vasiliev” | 413*912701f9SAndroid Build Coastguard Worker 414*912701f9SAndroid Build Coastguard WorkerIn Slavic languages, when _`addressing`_ a person (with `length="long"`), it might be 415*912701f9SAndroid Build Coastguard Worker 416*912701f9SAndroid Build Coastguard Worker* г-н Иван Петрович Васильев `// "Mr Ivan Petrovich Vasiliev"` 417*912701f9SAndroid Build Coastguard Worker 418*912701f9SAndroid Build Coastguard WorkerAnd when _`referring`_ to a person, it might place the surname first.: 419*912701f9SAndroid Build Coastguard Worker 420*912701f9SAndroid Build Coastguard Worker* Васильев Иван Петрович `// "Vasiliev Ivan Petrovich"` 421*912701f9SAndroid Build Coastguard Worker 422*912701f9SAndroid Build Coastguard WorkerThe `monogram` usage is for very short abbreviated names, such as might be found in online messaging text avatars or other annotations. Ideally, a `monogram` format should result in something that could fit in an em square. Some emoji provide examples of this: ️ 423*912701f9SAndroid Build Coastguard Worker 424*912701f9SAndroid Build Coastguard WorkerWhen used with `length`, for many alphabetic locales a `monogram` would resolve to one, two, or three characters for short, medium, and long respectively. But that may vary depending on the usage in a locale. 425*912701f9SAndroid Build Coastguard Worker 426*912701f9SAndroid Build Coastguard Worker### formality 427*912701f9SAndroid Build Coastguard Worker 428*912701f9SAndroid Build Coastguard WorkerThe `formality` indicates the formality of usage. A name on a badge for an informal gathering may be much different from an award announcement at the Nobel Prize Ceremonies. 429*912701f9SAndroid Build Coastguard Worker 430*912701f9SAndroid Build Coastguard WorkerNote that the formats may be the same for different formality scenarios depending on the length, usage, and cultural conventions for the locale. For example short formal and short informal may both be just the given name. 431*912701f9SAndroid Build Coastguard Worker 432*912701f9SAndroid Build Coastguard Worker| Parameter | Description | 433*912701f9SAndroid Build Coastguard Worker| ---------- | ----------- | 434*912701f9SAndroid Build Coastguard Worker| `formal` | A more formal name for the individual. The composition depends upon the language. For example, a particular locale might include the title, generation, credentials and a full middle name (given2) in the long form.<br/><br/>`length="medium", formality="formal"`<br/>“Robert J. Smith” | 435*912701f9SAndroid Build Coastguard Worker| `informal` | A less formal name for the individual. The composition depends upon the language. For example, a language might exclude the title, credentials and given2 (middle) name. Depending on the length, it may also exclude the surname. The formatting algorithm should choose any passed in name data that has an _informal_ attribute, if available.<br/><br/>`length="medium", formality="informal"`<br/>“Bob Smith” | 436*912701f9SAndroid Build Coastguard Worker 437*912701f9SAndroid Build Coastguard Worker## namePattern Syntax 438*912701f9SAndroid Build Coastguard Worker 439*912701f9SAndroid Build Coastguard WorkerA _namePattern_ is composed of a sequence of field IDs, each enclosed in curly braces, and separated by zero or more literal characters (eg, space or comma + space). An Extended Backus Normal Form (EBNF) is used to describe the namePattern format for a specific set of attributes. It has the following structure. This is the `( #PCDATA )` reference in the element specification above. 440*912701f9SAndroid Build Coastguard Worker 441*912701f9SAndroid Build Coastguard Worker| | EBNF | Comments | 442*912701f9SAndroid Build Coastguard Worker| ------------ | ----------------------------- | -------- | 443*912701f9SAndroid Build Coastguard Worker| namePattern | = literal?<br/><span style="white-space:nowrap">( modField literal? )+;</span> | Two literals cannot be adjacent | 444*912701f9SAndroid Build Coastguard Worker| modField | <span style="white-space:nowrap">= '{' field modifierList? '}';</span> | A name field, optionally modified | 445*912701f9SAndroid Build Coastguard Worker| field | = 'title'<br/>\| 'given'<br/>\| 'given2'<br/>\| 'surname'<br/>\| 'surname2'<br/>\| 'generation'<br/>\| 'credentials' ; | See [Fields](#fields) | 446*912701f9SAndroid Build Coastguard Worker| modifierList | = '-informal'?<br/><span style="white-space:nowrap">( '-allCaps' \| ‘-initialCap' )?;</span><br/><span style="white-space:nowrap">( '-initial' \| '-monogram' )?</span><br/><span style="white-space:nowrap">( '-prefix' \| '-core' )?</span> | Optional modifiers that can be applied to name parts, see [Modifiers](#modifiers). Note that some modifiers are exclusive: only `prefix` or `core`, only `initial` or `monogram`, only `allCaps` or `initialCap`. | 447*912701f9SAndroid Build Coastguard Worker| literal | = codepoint+ ; | One or more Unicode codepoints. | 448*912701f9SAndroid Build Coastguard Worker 449*912701f9SAndroid Build Coastguard Worker### Fields 450*912701f9SAndroid Build Coastguard Worker 451*912701f9SAndroid Build Coastguard WorkerThe Person Name formatting data assumes that the name data to be formatted consists of the fields in the table below. All of the fields may contain multiple words. Field IDs are lowercase ASCII alphanumeric, and start with an alphabetic character. 452*912701f9SAndroid Build Coastguard Worker 453*912701f9SAndroid Build Coastguard WorkerWhen determining how a full name is to be placed into name fields, the data to be formatted should be organized functionally. That is, if a name part is on the dividing line between `given2` and `given`, the key feature is whether it would always occur with the rest of the given name. For example, in _“Mary Jean Smith”_, if _“Mary”_ never occurs without the _“Jean”_, then the given name should be _“Mary Jean”_. If _“Smith”_ never occurs without the _“Jean”_, the `surname` should be _“Jean Smith”_. Otherwise, _“Jean”_ would be the `given2` field. 454*912701f9SAndroid Build Coastguard Worker 455*912701f9SAndroid Build Coastguard WorkerFor example, a patronymic would be treated as a `given2` name in most slavic languages. 456*912701f9SAndroid Build Coastguard Worker 457*912701f9SAndroid Build Coastguard WorkerIn some cultures, two surnames are used to indicate the paternal and maternal family names or generational names indicating father, grandfather. The `surname2` field is used to indicate this. The CLDR PersonName formatting data assumes that if a PersonName object to be formatted does not have two surnames, then the `surname2` field is not populated. (That is, no pattern should have a `surname2` field without a surname field.) Order of fields in a pattern can vary arbitrarily by locale. 458*912701f9SAndroid Build Coastguard Worker 459*912701f9SAndroid Build Coastguard WorkerIn most cultures, there is a concept of nickname or preferred name, which is used in informal settings or sometimes to represent a “public” or “stage name”. The nickname or preferred name may be submitted as a separate PersonName object to be formatted, or included with a modifier such as `given-informal`. 460*912701f9SAndroid Build Coastguard Worker 461*912701f9SAndroid Build Coastguard Worker| Field | Description<br/>Note: The values for each are as supplied by the PersonName object, via the PersonName data interface. | 462*912701f9SAndroid Build Coastguard Worker| ---------- | ----------- | 463*912701f9SAndroid Build Coastguard Worker| `title` | A title or honorific qualifier.<br/>Example: ‘Ms.’, ‘Mr.’, ’Dr’, ‘President’<br/><br/>Note that CLDR PersonName formats data does not define regional or locale-specific lists of titles or honorifics such as “Mr”, “Ms”, “Mx”, “Prof”, etc. | 464*912701f9SAndroid Build Coastguard Worker| `given` | The “given” name. Can be multiple words such as “Mary Ann”.<br/>Examples: “Janus”, “Mary Jean”, or “Jean-Louis”| 465*912701f9SAndroid Build Coastguard Worker| `given2` | Additional given name or names or middle name, usually names(s) written between the given and surname. Can be multiple words. In some references, also known as a “second” or “additional” given name or patronymic. This field is separate from the “given” field because it is often optional in various presentation forms.<br/>Examples: “Horatio Wallace” as in<br/>`{ given: "Janus", `**`given2: "Horatio Wallace"`**`, surname: "Young" }`<br/><br/>“S.” as in “Harry S. Truman”. Yes, his full middle name was legally just “S.”.| 466*912701f9SAndroid Build Coastguard Worker| `surname` | The “family name”. Can be more than one word.<br/><br/>Example: “van Gogh” as in<br/>`{ given: "Vincent", given2: "Willem", `**`surname: "van Gogh"`**` }`<br/><br/>Other examples: “Heathcote-Drummond-Willoughby” as in “William Emanuel Heathcote-Drummond-Willoughby III”| 467*912701f9SAndroid Build Coastguard Worker| `surname2` | Secondary surname (used in some cultures), such as second or maternal surname in Mexico and Spain. This field is separate from the “surname” field because it is often optional in various presentation forms, and is considered a separate distinct name in some cultures.<br/><br/>Example: “Barrientos” in “Diego Rivera Barrientos”;<br/>`{ given: "Diego", surname: "Rivera", `**`surname2: "Barrientos"`**` }`<br/><br/>Example: if "Mary Jane Smith" moves to Spain the new name may be<br/>`{ given: "Mary", given2: "Jane", surname: "Smith", `**`surname2: "Jones"`**` }`| 468*912701f9SAndroid Build Coastguard Worker| `credentials` | A credential or accreditation qualifier.<br/>Example: “PhD”, “MBA”<br/><br/>Example: “Salvatore Jarvis MBA”<br/>`{ given: "Salvatore", given2: "Blinken", surname: "Jarvis", `**`credentials: "MBA"`**` }`<br/><br/>An alternate PersonName object may be presented for formatting using the “stage” name from the application’s data:<br/>`{ given: "Salvatore", given-informal: "Salvatore", given2: "", surname: "Jarvis", `**`credentials: "MBA"`**` }` | 469*912701f9SAndroid Build Coastguard Worker| `generation` | A generation qualifier.<br/>Example: “III”, “Jr.”<br/><br/>Example: “Sonny Jarvis Jr.”<br/>`{ given: "Salvatore", given2: "Blinken", surname: "Jarvis", `**`generation: "Jr."`**` }` | 470*912701f9SAndroid Build Coastguard Worker 471*912701f9SAndroid Build Coastguard WorkerSome other examples: 472*912701f9SAndroid Build Coastguard Worker 473*912701f9SAndroid Build Coastguard Worker* British name: _John Ronald Reuel Tolkien_: `given` name is "John", `given2` name would be "Ronald Reuel", and the `surame` is "Tolkien". 474*912701f9SAndroid Build Coastguard Worker* Dutch name: _Anneliese Louise van der Pol_: `given` name: "Anneliese", `given2` name: "Louise", `surname`: "van der Pol" 475*912701f9SAndroid Build Coastguard Worker * Also surname-prefix: “van der”, surname-core: “Pol” — see below. 476*912701f9SAndroid Build Coastguard Worker* French name: “Jean-Louis Trintignant” would _not_ be Jean (`given`) Louis (`given2`) Trintignant (`surname`), since “Louis” wouldn’t be discarded when formatting. Instead it would be Jean-Louis (`given`) Trintignant (`surname`) 477*912701f9SAndroid Build Coastguard Worker 478*912701f9SAndroid Build Coastguard WorkerNote: If the legal name, stage name, etc. are substantially different, then that information can be logically in a separate PersonName object. That is, it is up to the implementation to maintain any distinctions that are important to it: CLDR PersonName formats is focusing on formatting a PersonName object that is given to it. 479*912701f9SAndroid Build Coastguard Worker 480*912701f9SAndroid Build Coastguard Worker`surname2` would only be asked for in certain locales, and where it is considered a separate, divisible name, such as in Mexico or Spain. For instance, in Mexico, the first and second surname are used for the legal name and in formal settings, and sometimes only the first surname is used in familiar or informal contexts. 481*912701f9SAndroid Build Coastguard Worker 482*912701f9SAndroid Build Coastguard Worker* Heathcote-Drummond is a single surname and would not be `{surname}-{surname2}` because we would never discard part of the name when formatting. 483*912701f9SAndroid Build Coastguard Worker* Spanish name: "Jose Luis Garcia Barrientos": The `given` name is “Jose”, the `given2` name is “Luis”, the `surname` is "Garcia”, and the `surname2` is “Barrientos" 484*912701f9SAndroid Build Coastguard Worker 485*912701f9SAndroid Build Coastguard WorkerHow names get placed into fields to be formatted is beyond the scope of CLDR PersonName formats; this document just lays out the assumptions the formatting code makes when formatting the names. 486*912701f9SAndroid Build Coastguard Worker 487*912701f9SAndroid Build Coastguard Worker### Modifiers 488*912701f9SAndroid Build Coastguard Worker 489*912701f9SAndroid Build Coastguard WorkerEach field in a pattern can have one or more modifiers. The modifiers can be appended to any field name, such as `{given-initial}` for the first grapheme of the given name. If more than one modifier is applied, they must be structured as in the EBNF. 490*912701f9SAndroid Build Coastguard Worker 491*912701f9SAndroid Build Coastguard WorkerThe modifiers transform the input data as described in the following table: 492*912701f9SAndroid Build Coastguard Worker 493*912701f9SAndroid Build Coastguard Worker| Modifier | Description | 494*912701f9SAndroid Build Coastguard Worker| ---------- | ----------- | 495*912701f9SAndroid Build Coastguard Worker| informal | Requests an informal version of the name if available. For example, {given} might be “Thomas”, and {given-informal} might be “Tom”. If there is no informal version, then the normal one is returned. An informal version should not be generated, because they vary too much: Beth, Betty, Betsy, Bette, Liz, … | 496*912701f9SAndroid Build Coastguard Worker| prefix | Return the “prefix” name, or the “tussenvoegsel'' if present. For example, “van der Poel” becomes “van der”, “bint Fadi” becomes “bint”, “di Santis” becomes “di”. Note that what constitutes the prefix is language- and locale-sensitive. It may be passed in as part of the PersonName object, similar to the _“-informal”_ modifier, e.g. as _“surname-prefix”_.<br/><br/>The implementation of this modifier depends on the PersonName object. CLDR does not currently provide support for automatic identification of tussenvoegsels, but may in the future.<br/><br/>If the resulting _“-prefix”_ value is empty, it defaults to an empty string.<br/><br/>An example sorting pattern for “Johannes van den Berg” may be<br/>{surname-core}, {given} {given2} {surname-prefix}<br/><br/>Only the _“-prefix”_ or the _“-core”_ modifier may be used, but not both. They are mutually exclusive. | 497*912701f9SAndroid Build Coastguard Worker| core | Return the “core” name, removing any tussenvoegsel. For example, “van der Poel” becomes “Poel”, “bint Fadi” becomes “Fadi”, “di Santis” becomes “Santis”. Note that what constitutes the core is language- and locale-sensitive.<br/><br/>The implementation of this modifier depends on the PersonName object. CLDR does not currently provide support for identification of tussenvoegsel, but may in the future.<br/><br/>If the resulting _“-core”_ value is empty, it defaults to the field it modifies. E.g., if _“surname-core”_ is empty in the PersonName object to be formatted, it will default to the _“surname”_ field.<br/><br/>Vice-versa, if the _surname_ field is empty, the formatter will attempt to use _surname-prefix_ and _surname-core_, if present, to format the name.<br/><br/>Only the _“-prefix”_ or the _“-core”_ modifier may be used, but not both. They are mutually exclusive. | 498*912701f9SAndroid Build Coastguard Worker| allCaps | Requests the element in all caps, which is desired In some contexts. For example, a new guideline in Japan is that for the Latin representation of Japanese names, the family name comes first and is presented in all capitals. This would be represented as<br/>“{surname-allCaps} {given}”<br/><br/>Hayao Miyazaki (宮崎 駿) would be represented in Latin characters in Japan (ja-Latn-JP) as _“MIYAZAKI Hayao”_<br/><br/>_The default implementation uses the default Unicode uppercase algorithm; if the PersonName object being formatted has a locale, and CLDR supports a locale-specific algorithm for that locale, then that algorithm is used. The PersonName object can override this, as detailed below._<br/><br/>Only the _“-allCaps”_ or the _“-initalCap”_ modifier may be used, but not both. They are mutually exclusive. | 499*912701f9SAndroid Build Coastguard Worker| initialCap | Request the element with the first grapheme capitalized, and remaining characters unchanged. This is used in cases where an element is usually in lower case but may need to be modified. For example in Dutch, the name<br/>{ title: “dhr.”, given: ”Johannes”, surname: “van den Berg” },<br/>when addressed formally, would need to be “dhr. Van den Berg”. This would be represented as<br/>“{title} {surname-initialCap}”<br/><br/>Only the _“-allCaps”_ or the _“-initalCap”_ modifier may be used, but not both. They are mutually exclusive. | 500*912701f9SAndroid Build Coastguard Worker| initial | Requests the initial grapheme cluster of each word in a field. The `initialPattern` patterns for the locale are used to create the format and layout for lists of initials. For example, if the initialPattern types are<br/>`<initialPattern type="initial">{0}.</initialPattern>`<br/>`<initialPattern type="initialSequence">{0} {1}</initialPattern>`<br/>then a name such as<br/>{ given: “John”, given2: “Ronald Reuel”, surname: “Tolkien” }<br/>could be represented as<br/>“{given-initial-allCaps} {given2-initial-allCaps} {surname}”<br/>and will format to “**J. R. R. Tolkien**”<br/><br/>_The default implementation uses the first grapheme cluster of each word for the value for the field; if the PersonName object has a locale, and CLDR supports a locale-specific grapheme cluster algorithm for that locale, then that algorithm is used. The PersonName object can override this, as detailed below._<br/><br/>Only the _“-initial”_ or the _“-monogram”_ modifier may be used, but not both. They are mutually exclusive. | 501*912701f9SAndroid Build Coastguard Worker| monogram | Requests initial grapheme. Example: A name such as<br/>{ given: “Landon”, given2: “Bainard Crawford”, surname: “Johnson” }<br/>could be represented as<br/>“{given-monogram-allCaps}{given2-monogram-allCaps}{surname-monogram-allCaps}”<br/>or “**LBJ**”<br/><br/>_The default implementation uses the first grapheme cluster of the value for the field; if the PersonName object has a locale, and CLDR supports a locale-specific grapheme cluster algorithm for that locale, then that algorithm is used. The PersonName object can override this, as detailed below. The difference between monogram an initial is that monogram only returns one element, not one element per word._<br/><br/>Only the _“-initial”_ or the _“-monogram”_ modifier may be used, but not both. They are mutually exclusive. | 502*912701f9SAndroid Build Coastguard Worker| retain | This is needed in languages that preserve punctuation when forming initials. For example, normally the name {given=Anne-Marie} is converted into initials with {given-initialCaps} as “A. M.”. However, where a language preserves the hyphen, the pattern should use {given-initialCaps**-retain**} instead. In that case, the result is “A.-M.”. (The periods are added by the pattern-initialSequence.) | 503*912701f9SAndroid Build Coastguard Worker| genitive, vocative | Patterns can use these modifiers so that better results can be obtained for inflected languages. However, see the details below. | 504*912701f9SAndroid Build Coastguard Worker 505*912701f9SAndroid Build Coastguard Worker#### Grammatical Modifiers for Names 506*912701f9SAndroid Build Coastguard Worker 507*912701f9SAndroid Build Coastguard WorkerThe CLDR person name formatting does not itself support grammatical inflection. 508*912701f9SAndroid Build Coastguard WorkerHowever, name sources (NameObject) can support inflections, either by having additional fields or by using an inflection engine that can handle personal name parts. 509*912701f9SAndroid Build Coastguard Worker 510*912701f9SAndroid Build Coastguard WorkerIn the current release, the focus is on supporting `referring` and `addressing` forms. 511*912701f9SAndroid Build Coastguard WorkerTypically the `referring` forms will be in the most neutral (*nominative*) case, and the `addressing` forms will be in the *vocative* case. 512*912701f9SAndroid Build Coastguard WorkerSome modifiers have been added to facilitate this, so that there can be patterns like: {given-vocative} {surname-vocative}. 513*912701f9SAndroid Build Coastguard Worker 514*912701f9SAndroid Build Coastguard WorkerNotice that some **parts** of the formatted name may be in different grammatical cases, so the cases may not be consistent across the whole name. 515*912701f9SAndroid Build Coastguard WorkerFor example: 516*912701f9SAndroid Build Coastguard Worker 517*912701f9SAndroid Build Coastguard Worker| English Pattern | Examples | Latvian Pattern | Examples | 518*912701f9SAndroid Build Coastguard Worker| ---- | ---- | ---- | ---- | 519*912701f9SAndroid Build Coastguard Worker| {given} {surname} | John Smith | {given} {surname} | Kārlis Ozoliņš | 520*912701f9SAndroid Build Coastguard Worker| {title} {surname} | Mr Smith | {surname} {title} | Ozoliņa kungs | 521*912701f9SAndroid Build Coastguard Worker 522*912701f9SAndroid Build Coastguard WorkerNotice that the `surname` in Latvian needs to change to the genitive case with that pattern: 523*912701f9SAndroid Build Coastguard Worker 524*912701f9SAndroid Build Coastguard WorkerOzoliņš ➡︎ **Ozoliņa** 525*912701f9SAndroid Build Coastguard Worker 526*912701f9SAndroid Build Coastguard WorkerThat is accomplished by changing the pattern to be {surname<b>-genitive</b>} {title}. In this case the {surname} should only be genitive if followed by the {title}. 527*912701f9SAndroid Build Coastguard Worker 528*912701f9SAndroid Build Coastguard Worker#### Future Modifiers 529*912701f9SAndroid Build Coastguard Worker 530*912701f9SAndroid Build Coastguard WorkerAdditional modifiers may be added in future versions of CLDR. 531*912701f9SAndroid Build Coastguard Worker 532*912701f9SAndroid Build Coastguard WorkerExamples: 533*912701f9SAndroid Build Coastguard Worker 534*912701f9SAndroid Build Coastguard Worker1. For the initial of the surname **_“de Souza”_**, in a language that treats the “de” as a tussenvoegsel, the PersonName object can automatically recast `{surname-initial}` to:<br/>`{surname-prefix-initial}{surname-core-initial-allCaps} `to get “dS” instead of “d”. 535*912701f9SAndroid Build Coastguard Worker2. If the locale expects a surname prefix to to be sorted after a surname, then both `{surname-core} `then `{surname-prefix}` would be used as in<br/>`{surname-core}, {given} {given2} {surname-prefix}` 536*912701f9SAndroid Build Coastguard Worker3. Only the grammatical modifiers requested by translators for `referring` or `addressing` have been added as yet, but additional grammatical modifiers may be added in the future. 537*912701f9SAndroid Build Coastguard Worker 538*912701f9SAndroid Build Coastguard Worker## Formatting Process 539*912701f9SAndroid Build Coastguard Worker 540*912701f9SAndroid Build Coastguard WorkerThe patterns are in **personName** elements, which are themselves in a **personNames** container element. The following describes how the formatter's locale interacts with the personName's locale, how the name patterns are chosen, and how they are processed. 541*912701f9SAndroid Build Coastguard Worker 542*912701f9SAndroid Build Coastguard WorkerThe details of the XML structure behind the data referenced here are in [XML Structure](#xml-structure). 543*912701f9SAndroid Build Coastguard Worker 544*912701f9SAndroid Build Coastguard WorkerThe formatting process may be refined in the future. In particular, additional data may be added to allow further customization. 545*912701f9SAndroid Build Coastguard Worker 546*912701f9SAndroid Build Coastguard WorkerThe term **maximal likely locale** used below is the result of using the [Likely Subtags](tr35.md#Likely_Subtags) data to map from a locale to a full representation that includes the base language, script, and region. 547*912701f9SAndroid Build Coastguard Worker 548*912701f9SAndroid Build Coastguard Worker### Derive the name locale 549*912701f9SAndroid Build Coastguard Worker 550*912701f9SAndroid Build Coastguard WorkerConstruct the **name script** in the following way. 551*912701f9SAndroid Build Coastguard Worker1. Iterate through the characters of the surname, then through the given name. 552*912701f9SAndroid Build Coastguard Worker 1. Find the script of that character using the Script property. 553*912701f9SAndroid Build Coastguard Worker 2. If the script is not Common, Inherited, nor Unknown, return that script as the **name script** 554*912701f9SAndroid Build Coastguard Worker2. If nothing is found during the iteration, return Zzzz (Unknown Script) 555*912701f9SAndroid Build Coastguard Worker 556*912701f9SAndroid Build Coastguard WorkerConstruct the **name base language** in the following way. 557*912701f9SAndroid Build Coastguard Worker1. If the PersonName object can provide a name locale, return its language. 558*912701f9SAndroid Build Coastguard Worker2. Otherwise, find the maximal likely locale for the name script and return its base language (first subtag). 559*912701f9SAndroid Build Coastguard Worker 560*912701f9SAndroid Build Coastguard WorkerConstruct the **name locale** in the following way: 561*912701f9SAndroid Build Coastguard Worker1. If the PersonName object can provide a name locale, return a locale formed from it by replacing its script by the name script. 562*912701f9SAndroid Build Coastguard Worker2. Otherwise, return the locale formed from the name base language plus name script. 563*912701f9SAndroid Build Coastguard Worker 564*912701f9SAndroid Build Coastguard WorkerConstruct the **name ordering locale** in the following way: 565*912701f9SAndroid Build Coastguard Worker1. If the PersonName object can provide a name locale, return it. 566*912701f9SAndroid Build Coastguard Worker2. Otherwise, return the maximal likely locale for “und-” + name script. 567*912701f9SAndroid Build Coastguard Worker 568*912701f9SAndroid Build Coastguard Worker### Derive the formatting locale 569*912701f9SAndroid Build Coastguard Worker 570*912701f9SAndroid Build Coastguard WorkerLet the **full formatting locale** be the maximal likely locale for the formatter's locale. The **formatting base language** is the base language (first subtag) of the full formatting locale, and the **formatting script** is the script code of the full formatting locale. 571*912701f9SAndroid Build Coastguard Worker 572*912701f9SAndroid Build Coastguard Worker#### Switch the formatting locale if necessary 573*912701f9SAndroid Build Coastguard Worker 574*912701f9SAndroid Build Coastguard WorkerA few script values represent a set of scripts, such as Jpan = {Hani, Kana, Hira}. Two script codes are said to _match_ when they are either identical, or one represents a set which contains the other, or they both represent sets which intersect. For example, Hani and Jpan match, because {Hani, Kana, Hira} contains Hani. 575*912701f9SAndroid Build Coastguard Worker 576*912701f9SAndroid Build Coastguard WorkerIf the **name script** doesn't match the **formatting script**: 577*912701f9SAndroid Build Coastguard Worker1. If the name locale has name formatting data, then set the formatting locale to the name locale. 578*912701f9SAndroid Build Coastguard Worker2. Otherwise, set the formatting locale to the maximal likely locale for the the locale formed from und, plus the name script plus the region of the nameLocale. 579*912701f9SAndroid Build Coastguard Worker 580*912701f9SAndroid Build Coastguard WorkerFor example, when a Hindi (Devanagari) formatter is called upon to format a name object that has the locale Ukrainian (Cyrillic): 581*912701f9SAndroid Build Coastguard Worker* If the name is written with Cyrillic letters, under the covers a Ukrainian (Cyrillic) formatter should be instantiated and used to format that name. 582*912701f9SAndroid Build Coastguard Worker* If the name is written in Greek letters, then under the covers a Greek (Greek-script) formatter should be instantiated and used to format. 583*912701f9SAndroid Build Coastguard Worker 584*912701f9SAndroid Build Coastguard WorkerTo determine whether there is name formatting data for a locale, get the values for each of the following paths. 585*912701f9SAndroid Build Coastguard WorkerIf at least one of them doesn’t inherit their value from root, then the locale has name formatting data. 586*912701f9SAndroid Build Coastguard Worker* //ldml/personNames/nameOrderLocales[@order="givenFirst"] 587*912701f9SAndroid Build Coastguard Worker* //ldml/personNames/nameOrderLocales[@order="surnameFirst"] 588*912701f9SAndroid Build Coastguard Worker 589*912701f9SAndroid Build Coastguard Worker### Derive the name order 590*912701f9SAndroid Build Coastguard Worker 591*912701f9SAndroid Build Coastguard WorkerA PersonName object’s fields are used to derive an order, as follows: 592*912701f9SAndroid Build Coastguard Worker 593*912701f9SAndroid Build Coastguard Worker1. If the calling API requests sorting order, that is used. 594*912701f9SAndroid Build Coastguard Worker2. Otherwise, if the PersonName object to be formatted has a `preferredOrder` field, then return that field’s value 595*912701f9SAndroid Build Coastguard Worker3. Otherwise, use the nameOrderLocales elements to find the best match for the name locale, as follows. 596*912701f9SAndroid Build Coastguard Worker 1. For each locale L1 in the parent locale lookup chain* for the **name ordering locale**, do the following 597*912701f9SAndroid Build Coastguard Worker 1. Create a locale L2 by replacing the language subtag by 'und'. (Eg, 'de_DE' ⇒ 'und_DE') 598*912701f9SAndroid Build Coastguard Worker 2. For each locale L in {L1, L2}, do the following 599*912701f9SAndroid Build Coastguard Worker 1. If there is a precise match among the givenFirst nameOrderLocales for L, then let the nameOrder be givenFirst, and stop. 600*912701f9SAndroid Build Coastguard Worker 2. Otherwise if there is a precise match among the surnameFirst nameOrderLocales for L, then let the nameOrder be surnameFirst, and stop. 601*912701f9SAndroid Build Coastguard Worker 2. Otherwise, let the nameOrder be givenFirst, and stop. 602*912701f9SAndroid Build Coastguard Worker 603*912701f9SAndroid Build Coastguard Worker\* For example, here is a parent locale lookup chain: 604*912701f9SAndroid Build Coastguard Worker 605*912701f9SAndroid Build Coastguard Worker de_Latn_DE ⇒ de_Latn ⇒ de_DE ⇒ de ⇒ und 606*912701f9SAndroid Build Coastguard Worker 607*912701f9SAndroid Build Coastguard WorkerIn other words, with the name locale of `de_Latin_DE` you'll check the givenFirst and surnameFirst resources for the following locales, in this order: 608*912701f9SAndroid Build Coastguard Worker 609*912701f9SAndroid Build Coastguard Worker de_Latin_DE, und_Latn_DE, de_Latn, und_Latn, de_DE, und_DE, de, und 610*912701f9SAndroid Build Coastguard Worker 611*912701f9SAndroid Build Coastguard WorkerThis process will always terminate, because there is always a und value in one of the two nameOrderLocales elements. Remember that the lookup chain requires use of the parentLocales elements: it is not just truncation. 612*912701f9SAndroid Build Coastguard Worker 613*912701f9SAndroid Build Coastguard WorkerFor example, the data for a particular locale might look like the following: 614*912701f9SAndroid Build Coastguard Worker 615*912701f9SAndroid Build Coastguard Worker```xml 616*912701f9SAndroid Build Coastguard Worker<nameOrderLocales order="surnameFirst">zh ja und-CN und-TW und-SG und-HK und-MO und-HU und-JP</nameOrderLocales> 617*912701f9SAndroid Build Coastguard Worker``` 618*912701f9SAndroid Build Coastguard WorkerThese nameOrderLocales will match any locale with a zh or ja [unicode_language_subtag](tr35.md#unicode_language_subtag) and any locale with a CN, TW, SG, HK MO, HU, or JP [unicode_region_subtag](tr35.md#unicode_region_subtag). 619*912701f9SAndroid Build Coastguard Worker 620*912701f9SAndroid Build Coastguard WorkerHere are some more examples. Note that if there is no order field or locale field in the PersonName object to be formatted, and the script of the PersonName data is different from that of the formatting locale, then the default result is givenFirst. 621*912701f9SAndroid Build Coastguard Worker 622*912701f9SAndroid Build Coastguard Worker| PersonName Object preferredOrder | PersonName Object Locale | Resulting Order | 623*912701f9SAndroid Build Coastguard Worker| -------------------------------- | ------------------------ | --------------- | 624*912701f9SAndroid Build Coastguard Worker| surnameFirst | ? | surnameFirst | 625*912701f9SAndroid Build Coastguard Worker| | zh | surnameFirst | 626*912701f9SAndroid Build Coastguard Worker| | und-JP | surnameFirst | 627*912701f9SAndroid Build Coastguard Worker| | fr | givenFirst | 628*912701f9SAndroid Build Coastguard Worker| | | givenFirst | 629*912701f9SAndroid Build Coastguard Worker 630*912701f9SAndroid Build Coastguard Worker### Choose a personName element 631*912701f9SAndroid Build Coastguard Worker 632*912701f9SAndroid Build Coastguard WorkerThe personName data in CLDR provides representations for how names are to be formatted across the different axes of _order_, _length_, _usage_, and _formality_. More than one `namePattern` can be associated with a single `personName` entry. An algorithm is then used to choose the best `namePattern` to use. 633*912701f9SAndroid Build Coastguard Worker 634*912701f9SAndroid Build Coastguard WorkerAs an example for English, this may look like: 635*912701f9SAndroid Build Coastguard Worker 636*912701f9SAndroid Build Coastguard Worker```xml 637*912701f9SAndroid Build Coastguard Worker<personNames> 638*912701f9SAndroid Build Coastguard Worker <personName order="givenFirst" length="long" usage="referring" formality="formal"> 639*912701f9SAndroid Build Coastguard Worker <namePattern>{title} {given} {given2} {surname}, {credentials}</namePattern> 640*912701f9SAndroid Build Coastguard Worker </personName> 641*912701f9SAndroid Build Coastguard Worker <personName order="givenFirst" length="long" usage="referring" formality="informal"> 642*912701f9SAndroid Build Coastguard Worker <namePattern>{given} «{given2}» {surname}</namePattern> 643*912701f9SAndroid Build Coastguard Worker <namePattern alt="2">«{given2}» {surname}</namePattern> 644*912701f9SAndroid Build Coastguard Worker </personName> 645*912701f9SAndroid Build Coastguard Worker <personName order="givenFirst" length="long" usage="sorting" formality="informal"> 646*912701f9SAndroid Build Coastguard Worker <namePattern>{surname}, {given} {given2}</namePattern> 647*912701f9SAndroid Build Coastguard Worker </personName> 648*912701f9SAndroid Build Coastguard Worker ... 649*912701f9SAndroid Build Coastguard Worker</personNames> 650*912701f9SAndroid Build Coastguard Worker``` 651*912701f9SAndroid Build Coastguard Worker 652*912701f9SAndroid Build Coastguard WorkerThe task is to find the best personName for a given set of input attributes. Well-formed data will always cover all possible combinations of the input parameters, so the algorithm is simple: traverse the list of person names until the first match is found, then return it. 653*912701f9SAndroid Build Coastguard Worker 654*912701f9SAndroid Build Coastguard WorkerIn more detail: 655*912701f9SAndroid Build Coastguard Worker 656*912701f9SAndroid Build Coastguard WorkerA set of input parameters { order=O length=L usage=U formality=F } matches a personName element when: 657*912701f9SAndroid Build Coastguard Worker 658*912701f9SAndroid Build Coastguard Worker* The order attribute values contain O or there is no order attribute, and 659*912701f9SAndroid Build Coastguard Worker* The length attribute values contain L or there is no length attribute, and 660*912701f9SAndroid Build Coastguard Worker* The usage attribute values contain U or there is no usage attribute, and 661*912701f9SAndroid Build Coastguard Worker* The formality attribute values contain F or there is no formality attribute 662*912701f9SAndroid Build Coastguard Worker 663*912701f9SAndroid Build Coastguard WorkerExample for input parameters 664*912701f9SAndroid Build Coastguard Worker 665*912701f9SAndroid Build Coastguard Worker> `order = `**`givenFirst`**`, length = `**`long`**`, usage = `**`referring`**`, formality = `**`formal`** 666*912701f9SAndroid Build Coastguard Worker 667*912701f9SAndroid Build Coastguard WorkerTo match a personName, all four attributes in the personName must match (a missing attribute matches any value for that attribute): 668*912701f9SAndroid Build Coastguard Worker 669*912701f9SAndroid Build Coastguard Worker| Sample personName attributes | Matches? | Comment | 670*912701f9SAndroid Build Coastguard Worker| :----------------------------------------------------------- | :------: | :------ | 671*912701f9SAndroid Build Coastguard Worker| `order=`_`"givenFirst"`_` length=`_`"long"`_` usage=`_`"referring"`_` formality=`_`"formal"`_ | Y | exact match | 672*912701f9SAndroid Build Coastguard Worker| `length=`_`"long"`_` usage=`_`"referring"`_` formality=`_`"informal"`_ | N | mismatch for formality | 673*912701f9SAndroid Build Coastguard Worker| `length=`_`"long"`_` formality=`_`"formal"`_ | Y | missing usage = all! | 674*912701f9SAndroid Build Coastguard Worker 675*912701f9SAndroid Build Coastguard WorkerTo find the matching personName element, traverse all the personNames in order until the first one is found. This will always terminate since the data is well-formed in CLDR. 676*912701f9SAndroid Build Coastguard Worker 677*912701f9SAndroid Build Coastguard Worker### Choose a namePattern 678*912701f9SAndroid Build Coastguard Worker 679*912701f9SAndroid Build Coastguard WorkerTo format a name, the fields in a namePattern are replaced with fields fetched from the PersonName Data Interface. The personName element can contain multiple namePattern elements. Choose one based on the fields in the input PersonName object that are populated: 680*912701f9SAndroid Build Coastguard Worker1. Find the set of patterns with the most populated fields. 681*912701f9SAndroid Build Coastguard Worker2. If there is just one element in that set, use it. 682*912701f9SAndroid Build Coastguard Worker2. Otherwise, among that set, find the set of patterns with the fewest unpopulated fields. 683*912701f9SAndroid Build Coastguard Worker3. If there is just one element in that set, use it. 684*912701f9SAndroid Build Coastguard Worker4. Otherwise, take the pattern that is alphabetically least. (This step should rarely happen, and is only for producing a determinant result.) 685*912701f9SAndroid Build Coastguard Worker 686*912701f9SAndroid Build Coastguard WorkerFor example: 687*912701f9SAndroid Build Coastguard Worker 688*912701f9SAndroid Build Coastguard Worker1. Pattern A has 12 fields total, pattern B has 10 fields total, and pattern C has 8 fields total. 689*912701f9SAndroid Build Coastguard Worker2. Both patterns A and B can be populated with 7 fields from the input PersonName object, pattern C can be populated with only 3 fields from the input PersonName object. 690*912701f9SAndroid Build Coastguard Worker3. Pattern C is discarded, because it has the least number of populated name fields. 691*912701f9SAndroid Build Coastguard Worker4. Out of the remaining patterns A and B, pattern B wins, because it has only 3 unpopulated fields compared to pattern A. 692*912701f9SAndroid Build Coastguard Worker 693*912701f9SAndroid Build Coastguard Worker### Access PersonName object 694*912701f9SAndroid Build Coastguard Worker 695*912701f9SAndroid Build Coastguard Worker#### Handle missing surname 696*912701f9SAndroid Build Coastguard Worker 697*912701f9SAndroid Build Coastguard WorkerAll PersonName objects will have a given name (for mononyms the given name is used). However, there may not be a surname. In that case, the following process is followed so that formatted patterns produce reasonable results. 698*912701f9SAndroid Build Coastguard Worker 699*912701f9SAndroid Build Coastguard Worker1. If there is no surname from a PersonName P1 _and_ the pattern either doesn't include the given name or only shows an initial for the given name, then: 700*912701f9SAndroid Build Coastguard Worker 1. Construct and use a derived PersonName P2, whereby P2 behaves exactly as P1 except that: 701*912701f9SAndroid Build Coastguard Worker 1. Any request for a surname field (with any modifiers) returns P1's given name (with the same modifiers) 702*912701f9SAndroid Build Coastguard Worker 2. Any request for a given name field (with any modifiers) returns "" (empty string) 703*912701f9SAndroid Build Coastguard Worker 704*912701f9SAndroid Build Coastguard WorkerAs always, this is a logical description and may be optimized in implementations. For example, an implemenation may use an interface for P2 that just delegates calls to P1, with some redirection for accesses to surname and given name. 705*912701f9SAndroid Build Coastguard Worker 706*912701f9SAndroid Build Coastguard Worker#### Handle core and prefix 707*912701f9SAndroid Build Coastguard Worker 708*912701f9SAndroid Build Coastguard WorkerA given field may have a core value, a prefix value, and/or a ‘plain’ value (neither core nor prefix). If one or more of them are missing, then the returned values should be adjusted according to the table below. In the three cells on the left, a ✓ indicates that a value is available, an ✖️ if there is none. In three cells on the right, the value of = means the returned value is unchanged, ✖️ means the returned value is “empty”, and anything else is a description of what to change it to. 709*912701f9SAndroid Build Coastguard Worker 710*912701f9SAndroid Build Coastguard Worker| prefix | core | plain | | prefix | core | plain | 711*912701f9SAndroid Build Coastguard Worker| ------ | ---- | ----- |-| ------ | ---- | ----- | 712*912701f9SAndroid Build Coastguard Worker| ✓ | ✓ | ✓ | | = | = | = | 713*912701f9SAndroid Build Coastguard Worker| ✓ | ✖️ | ✓ | | ✖️ | plain | = | 714*912701f9SAndroid Build Coastguard Worker| ✖️ | ✓ | ✓ | | = | plain | = | 715*912701f9SAndroid Build Coastguard Worker| ✖️ | ✖️ | ✓ | | = | plain | = | 716*912701f9SAndroid Build Coastguard Worker| ✓ | ✓ | ✖️ | | = | = | prefix + " " + core | 717*912701f9SAndroid Build Coastguard Worker| ✖️ | ✓ | ✖️ | | = | = | core | 718*912701f9SAndroid Build Coastguard Worker| ✓ | ✖️ | ✖️ | | ✖️ | = | = | 719*912701f9SAndroid Build Coastguard Worker| ✖️ | ✖️ | ✖️ | | = | = | = | 720*912701f9SAndroid Build Coastguard Worker 721*912701f9SAndroid Build Coastguard WorkerFor example, if the surname-prefix is "von und zu" and the surname-core is "Stettbach" and there is no surname (plain), then the derived value for the (plain) surname is "von und zu Stettbach". (The cases where existing prefix values are changed should not be necessary with well-formed PersonName data.) 722*912701f9SAndroid Build Coastguard Worker 723*912701f9SAndroid Build Coastguard Worker#### Derive initials 724*912701f9SAndroid Build Coastguard Worker 725*912701f9SAndroid Build Coastguard WorkerThe following process is used to produce initials when they are not supplied by the PersonName object. Assuming the input example is “Mary Beth”: 726*912701f9SAndroid Build Coastguard Worker 727*912701f9SAndroid Build Coastguard Worker| Action | Result | 728*912701f9SAndroid Build Coastguard Worker| ------------------- | ------ | 729*912701f9SAndroid Build Coastguard Worker| 1. Split into words | “Mary” and “Beth” | 730*912701f9SAndroid Build Coastguard Worker| 2. Fetch the first grapheme cluster of each word | “M” and “B” | 731*912701f9SAndroid Build Coastguard Worker| 3. The ***initial*** pattern is applied to each<br/>` <initialPattern type="initial">{0}.</initialPattern>` | “M.” and “B.” | 732*912701f9SAndroid Build Coastguard Worker| 4. Finally recombined with ***initialSequence***<br/>` <initialPattern type="initialSequence">{0} {1}</initialPattern>` | “M. B.” | 733*912701f9SAndroid Build Coastguard Worker 734*912701f9SAndroid Build Coastguard WorkerSee the “initial” modifier in the [Modifiers](#modifiers) section for more details. 735*912701f9SAndroid Build Coastguard Worker 736*912701f9SAndroid Build Coastguard Worker### Process a namePattern 737*912701f9SAndroid Build Coastguard Worker 738*912701f9SAndroid Build Coastguard WorkerThe “winning” namePattern may still have fields that are unpopulated (empty) in the PersonName object. That namePattern is populated with field values with the following steps: 739*912701f9SAndroid Build Coastguard Worker 740*912701f9SAndroid Build Coastguard Worker1. If one or more fields at the start of the pattern are empty, all fields and literal text before the **first** populated field are omitted. 741*912701f9SAndroid Build Coastguard Worker2. If one or more fields at the end of the pattern are empty, all fields and literal text after the **last** populated field are omitted. 742*912701f9SAndroid Build Coastguard Worker3. Processing from the start of the remaining pattern: 743*912701f9SAndroid Build Coastguard Worker 1. If there are two or more empty fields separated only by literals, the fields and the literals between them are removed. 744*912701f9SAndroid Build Coastguard Worker 2. If there is a single empty field, it is removed. 745*912701f9SAndroid Build Coastguard Worker4. If the processing from step 3 results in two adjacent literals (call them A and B), they are coalesced into one literal as follows: 746*912701f9SAndroid Build Coastguard Worker 1. If either is empty the result is the other one. 747*912701f9SAndroid Build Coastguard Worker 2. If B matches the end of A, then the result is A. So xyz + yz ⇒ xyz, and xyz + xyz ⇒ xyz. 748*912701f9SAndroid Build Coastguard Worker 3. Otherwise the result is A + B, further modified by replacing any sequence of two or more white space characters by the first whitespace character. 749*912701f9SAndroid Build Coastguard Worker5. All of the fields are replaced by the corresponding values from the PersonName object. 750*912701f9SAndroid Build Coastguard Worker 751*912701f9SAndroid Build Coastguard WorkerThe result is the **formatted value**. However, there is one further step that might further modify that value. 752*912701f9SAndroid Build Coastguard Worker 753*912701f9SAndroid Build Coastguard Worker#### Handling foreign names 754*912701f9SAndroid Build Coastguard Worker 755*912701f9SAndroid Build Coastguard WorkerThere are two main challenges in dealing with foreign name formatting that needs to be considered. One is the ordering, which is dealt with under the section [nameOrderLocales Element](#nameorderlocales-element)]. The other is spacing. 756*912701f9SAndroid Build Coastguard Worker 757*912701f9SAndroid Build Coastguard WorkerSome writing systems require spaces (or some other non-letters) to separate words. For example, [Hayao Miyazaki](https://en.wikipedia.org/wiki/Hayao_Miyazaki) is written in English with given name first and with a space between the two name fields, while in Japanese there is no space with surname first: [宮崎駿](https://ja.wikipedia.org/wiki/%E5%AE%AE%E5%B4%8E%E9%A7%BF) 758*912701f9SAndroid Build Coastguard Worker 759*912701f9SAndroid Build Coastguard WorkerIf a locale requires spaces between words, the normal patterns for the formatting locale are used. On Wikipedia, for example, note the space within the Japanese name on pages from English and Korean (an ideographic space is used here for emphasis). 760*912701f9SAndroid Build Coastguard Worker 761*912701f9SAndroid Build Coastguard Worker* “[Hayao Miyazaki (宮崎<span style="background-color:aqua"> </span>駿, Miyazaki Hayao](https://en.wikipedia.org/wiki/Hayao_Miyazaki)…” or 762*912701f9SAndroid Build Coastguard Worker* “[미야자키<span style="background-color:aqua"> </span>하야오(일본어: 宮﨑<span style="background-color:aqua"> </span>駿 Miyazaki Hayao](https://ko.wikipedia.org/wiki/%EB%AF%B8%EC%95%BC%EC%9E%90%ED%82%A4_%ED%95%98%EC%95%BC%EC%98%A4)…”. 763*912701f9SAndroid Build Coastguard Worker 764*912701f9SAndroid Build Coastguard WorkerIf a locale **doesn’t** require spaces between words, there are two cases, based on whether the name is foreign or not (based on the PersonName objects explicit or calculated locale's language subtag). For example, the formatting locale might be Japanese, and the locale of the PersonName object might be de_CH, German (Switzerland), such as Albert Einstein. When the locale is foreign, the **foreignSpaceReplacement** is substituted for each space in the formatted name. When the name locale is native, a **nativeSpaceReplacement** is substituted for each space in the formatted name. The precise algorithm is given below. 765*912701f9SAndroid Build Coastguard Worker 766*912701f9SAndroid Build Coastguard WorkerHere are examples for Albert Einstein in Japanese and Chinese: 767*912701f9SAndroid Build Coastguard Worker* [アルベルト<span style="background-color:aqua">・</span>アインシュタイン](https://ja.wikipedia.org/wiki/%E3%82%A2%E3%83%AB%E3%83%99%E3%83%AB%E3%83%88%E3%83%BB%E3%82%A2%E3%82%A4%E3%83%B3%E3%82%B7%E3%83%A5%E3%82%BF%E3%82%A4%E3%83%B3) 768*912701f9SAndroid Build Coastguard Worker* [阿尔伯特<span style="background-color:aqua">·</span>爱因斯坦](https://zh.wikipedia.org/wiki/%E9%98%BF%E5%B0%94%E4%BC%AF%E7%89%B9%C2%B7%E7%88%B1%E5%9B%A0%E6%96%AF%E5%9D%A6) 769*912701f9SAndroid Build Coastguard Worker 770*912701f9SAndroid Build Coastguard Worker#### Setting the spaceReplacement 771*912701f9SAndroid Build Coastguard Worker 772*912701f9SAndroid Build Coastguard Worker1. The foreignSpaceReplacement is provided by the value for the `foreignSpaceReplacement` element; the default value is a SPACE (" "). 773*912701f9SAndroid Build Coastguard Worker2. The nativeSpaceReplacement is provided by the value for the `nativeSpaceReplacement` element; the default value is SPACE (" "). 774*912701f9SAndroid Build Coastguard Worker3. If the formatter base language matches the name base language, then let spaceReplacement = nativeSpaceReplacement, otherwise let spaceReplacement = foreignSpaceReplacement. 775*912701f9SAndroid Build Coastguard Worker4. Replace all sequences of space in the formatted value string by the spaceReplacement. 776*912701f9SAndroid Build Coastguard Worker 777*912701f9SAndroid Build Coastguard WorkerFor the purposes of this algorithm, two base languages are said to __match__ when they are identical, or if both are in {ja, zh, yue}. 778*912701f9SAndroid Build Coastguard Worker 779*912701f9SAndroid Build Coastguard Worker**Note:** in the future the plan is to make the specific languages and scripts used in this algorithm be data-driven. 780*912701f9SAndroid Build Coastguard Worker 781*912701f9SAndroid Build Coastguard WorkerRemember that **a name in a different script** will use a different locale for formatting, as per [Switch the formatting locale if necessary](#switch-the-formatting-locale-if-necessary). 782*912701f9SAndroid Build Coastguard WorkerFor example, when formatting a name for Japanese, if the name is in the Latin script, a Latin based locale will be used to format it, such as when “Albert Einstein” appears in Latin characters as in the Wikipedia page [Albert Einstein](https://ja.wikipedia.org/wiki/Albert_Einstein). 783*912701f9SAndroid Build Coastguard Worker 784*912701f9SAndroid Build Coastguard Worker#### Examples of space replacement 785*912701f9SAndroid Build Coastguard Worker 786*912701f9SAndroid Build Coastguard WorkerTo illustrate how foreign space replacement works, consider the following name data. For illustration, the name locale is given in the maximized form: in practice, `ja` would be used instead of `ja_Jpan_JP`, and so on.: For more information, see [Likely Subtags](tr35.md#Likely_Subtags). 787*912701f9SAndroid Build Coastguard Worker 788*912701f9SAndroid Build Coastguard Worker| name locale | given | surname | 789*912701f9SAndroid Build Coastguard Worker| ------------- | -------- | ------------- | 790*912701f9SAndroid Build Coastguard Worker| `de_Latn_CH` | Albert | Einstein | 791*912701f9SAndroid Build Coastguard Worker| `de_Kata_CH` | アルベルト | アインシュタイン | 792*912701f9SAndroid Build Coastguard Worker| `ja_Kata_CH` | アルベルト | アインシュタイン | 793*912701f9SAndroid Build Coastguard Worker| `ja_Latn_JP` | Hayao | Miyazaki | 794*912701f9SAndroid Build Coastguard Worker| `ja_Jpan_JP` | 駿 | 宮崎 | 795*912701f9SAndroid Build Coastguard Worker 796*912701f9SAndroid Build Coastguard WorkerSuppose the PersonNames formatting patterns for `ja_JP` and `de_CH` contained the following: 797*912701f9SAndroid Build Coastguard Worker 798*912701f9SAndroid Build Coastguard Worker**`ja_JP` formatting patterns** 799*912701f9SAndroid Build Coastguard Worker 800*912701f9SAndroid Build Coastguard Worker<pre> 801*912701f9SAndroid Build Coastguard Worker<personNames> 802*912701f9SAndroid Build Coastguard Worker <nameOrderLocales order="givenFirst">und</nameOrderLocales> 803*912701f9SAndroid Build Coastguard Worker <<strong>nameOrderLocales</strong> order="<strong>surnameFirst</strong>">hu <strong>ja</strong> ko vi yue zh <strong>und_JP</strong></nameOrderLocales> 804*912701f9SAndroid Build Coastguard Worker <<strong>nativeSpaceReplacement</strong> xml:space="preserve"><span style="background-color:aqua"></span></nativeSpaceReplacement> 805*912701f9SAndroid Build Coastguard Worker <<strong>foreignSpaceReplacement</strong> xml:space="preserve"><span style="background-color:aqua">・</span></foreignSpaceReplacement> 806*912701f9SAndroid Build Coastguard Worker . . . 807*912701f9SAndroid Build Coastguard Worker <personName order="<strong>givenFirst</strong>" length="medium" usage="referring" formality="formal"> 808*912701f9SAndroid Build Coastguard Worker <namePattern>{given}<span style="background-color:aqua"> </span>{given2}<span style="background-color:aqua"> </span>{surname}{generation}</namePattern> 809*912701f9SAndroid Build Coastguard Worker </personName> 810*912701f9SAndroid Build Coastguard Worker . . . 811*912701f9SAndroid Build Coastguard Worker <personName order="<strong>surnameFirst</strong>" length="medium" usage="referring" formality="formal"> 812*912701f9SAndroid Build Coastguard Worker <namePattern>{surname}{given2}{given}{generation}</namePattern> 813*912701f9SAndroid Build Coastguard Worker </personName> 814*912701f9SAndroid Build Coastguard Worker . . . 815*912701f9SAndroid Build Coastguard Worker</personNames> 816*912701f9SAndroid Build Coastguard Worker</pre> 817*912701f9SAndroid Build Coastguard Worker 818*912701f9SAndroid Build Coastguard WorkerNote in the `de_CH` locale, _ja_ is not listed in nameOrderLocales, and would therefore fall under _und_, and be formatted using the givenFirst order patterns if the name data is in the same script as the formatting locale. 819*912701f9SAndroid Build Coastguard Worker 820*912701f9SAndroid Build Coastguard Worker**`de_CH` formatting patterns** 821*912701f9SAndroid Build Coastguard Worker 822*912701f9SAndroid Build Coastguard Worker<pre> 823*912701f9SAndroid Build Coastguard Worker<personNames> 824*912701f9SAndroid Build Coastguard Worker <nameOrderLocales order="<strong>givenFirst</strong>">und <strong>de</strong></nameOrderLocales> 825*912701f9SAndroid Build Coastguard Worker <nameOrderLocales order="surnameFirst">ko vi yue zh</nameOrderLocales> 826*912701f9SAndroid Build Coastguard Worker <foreignSpaceReplacemen xml:space="preserve"><span style="background-color:aqua"> </span></foreignSpaceReplacement> 827*912701f9SAndroid Build Coastguard Worker . . . 828*912701f9SAndroid Build Coastguard Worker <personName order="givenFirst" length="medium" usage="referring" formality="formal"> 829*912701f9SAndroid Build Coastguard Worker <namePattern>{given}<span style="background-color:aqua"> </span>{given2-initial}<span style="background-color:aqua"> </span>{surname}, {generation}</namePattern> 830*912701f9SAndroid Build Coastguard Worker </personName> 831*912701f9SAndroid Build Coastguard Worker . . . 832*912701f9SAndroid Build Coastguard Worker <personName order="surnameFirst" length="medium" usage="referring" formality="formal"> 833*912701f9SAndroid Build Coastguard Worker <namePattern>{surname}<span style="background-color:aqua">, </span>{given}<span style="background-color:aqua"> </span>{given2-initial}<span style="background-color:aqua">,</span> {generation}</namePattern> 834*912701f9SAndroid Build Coastguard Worker </personName> 835*912701f9SAndroid Build Coastguard Worker . . . 836*912701f9SAndroid Build Coastguard Worker</personNames>` 837*912701f9SAndroid Build Coastguard Worker</pre> 838*912701f9SAndroid Build Coastguard Worker 839*912701f9SAndroid Build Coastguard WorkerThe name data would resolve as follows: 840*912701f9SAndroid Build Coastguard Worker<!-- TODO Replace the following with a markdown table --> 841*912701f9SAndroid Build Coastguard Worker 842*912701f9SAndroid Build Coastguard Worker<table> 843*912701f9SAndroid Build Coastguard Worker <tr> 844*912701f9SAndroid Build Coastguard Worker <td colspan="7" ><strong>formatting locale: ja_JP, </strong>script is Jpan which includes Hani, Hira and Kana</td> 845*912701f9SAndroid Build Coastguard Worker </tr> 846*912701f9SAndroid Build Coastguard Worker <tr> 847*912701f9SAndroid Build Coastguard Worker <td><strong>name locale</strong></td> 848*912701f9SAndroid Build Coastguard Worker <td><strong>given</strong></td> 849*912701f9SAndroid Build Coastguard Worker <td><strong>surname</strong></td> 850*912701f9SAndroid Build Coastguard Worker <td><strong>same<br/>script</strong></td> 851*912701f9SAndroid Build Coastguard Worker <td><strong>formatting<br/>locale</strong</td> 852*912701f9SAndroid Build Coastguard Worker <td><strong>order</strong></td> 853*912701f9SAndroid Build Coastguard Worker <td><strong>foreign<br/>space</strong></td> 854*912701f9SAndroid Build Coastguard Worker </tr> 855*912701f9SAndroid Build Coastguard Worker <tr> 856*912701f9SAndroid Build Coastguard Worker <td>de_Latn_CH</td> 857*912701f9SAndroid Build Coastguard Worker <td>Albert</td> 858*912701f9SAndroid Build Coastguard Worker <td><span style="text-decoration:underline;">Einstein</span></td> 859*912701f9SAndroid Build Coastguard Worker <td>NO</td> 860*912701f9SAndroid Build Coastguard Worker <td>de</td> 861*912701f9SAndroid Build Coastguard Worker <td>given First</td> 862*912701f9SAndroid Build Coastguard Worker <td></td> 863*912701f9SAndroid Build Coastguard Worker </tr> 864*912701f9SAndroid Build Coastguard Worker <tr> 865*912701f9SAndroid Build Coastguard Worker <td colspan="7" style="text-align:center">“Albert <span style="text-decoration:underline;">Einstein</span>”</td> 866*912701f9SAndroid Build Coastguard Worker </tr> 867*912701f9SAndroid Build Coastguard Worker <tr> 868*912701f9SAndroid Build Coastguard Worker <td>de_Jpan_CH</td> 869*912701f9SAndroid Build Coastguard Worker <td>アルベルト</td> 870*912701f9SAndroid Build Coastguard Worker <td><span style="text-decoration:underline;">アインシュタイン</span></td> 871*912701f9SAndroid Build Coastguard Worker <td>YES</td> 872*912701f9SAndroid Build Coastguard Worker <td>und</td> 873*912701f9SAndroid Build Coastguard Worker <td>given First</td> 874*912701f9SAndroid Build Coastguard Worker <td>“<span style="background-color:aqua">・</span>”</td> 875*912701f9SAndroid Build Coastguard Worker </tr> 876*912701f9SAndroid Build Coastguard Worker <tr> 877*912701f9SAndroid Build Coastguard Worker <td colspan="7" style="text-align:center">“アルベルト<span style="background-color:aqua">・</span><span style="text-decoration:underline;">アインシュタイン</span>”</td> 878*912701f9SAndroid Build Coastguard Worker </tr> 879*912701f9SAndroid Build Coastguard Worker <tr> 880*912701f9SAndroid Build Coastguard Worker <td>ja_Jpan_JP</td> 881*912701f9SAndroid Build Coastguard Worker <td>駿</td> 882*912701f9SAndroid Build Coastguard Worker <td><span style="text-decoration:underline;">宮崎</span></td> 883*912701f9SAndroid Build Coastguard Worker <td>YES</td> 884*912701f9SAndroid Build Coastguard Worker <td>ja</td> 885*912701f9SAndroid Build Coastguard Worker <td>surname First</td> 886*912701f9SAndroid Build Coastguard Worker <td></td> 887*912701f9SAndroid Build Coastguard Worker </tr> 888*912701f9SAndroid Build Coastguard Worker <tr> 889*912701f9SAndroid Build Coastguard Worker <td colspan="7" style="text-align:center"><span style="text-decoration:underline;">宮崎</span>駿</td> 890*912701f9SAndroid Build Coastguard Worker </tr> 891*912701f9SAndroid Build Coastguard Worker</table> 892*912701f9SAndroid Build Coastguard Worker<br/> 893*912701f9SAndroid Build Coastguard Worker 894*912701f9SAndroid Build Coastguard Worker<table> 895*912701f9SAndroid Build Coastguard Worker <tr> 896*912701f9SAndroid Build Coastguard Worker <td colspan="7" ><strong>formatting locale: de_CH</strong>, formatting locale script is Latn</td> 897*912701f9SAndroid Build Coastguard Worker </tr> 898*912701f9SAndroid Build Coastguard Worker <tr> 899*912701f9SAndroid Build Coastguard Worker <td><strong>name locale</strong></td> 900*912701f9SAndroid Build Coastguard Worker <td><strong>given</strong></td> 901*912701f9SAndroid Build Coastguard Worker <td><strong>surname</strong></td> 902*912701f9SAndroid Build Coastguard Worker <td><strong>same<br/>script</strong></td> 903*912701f9SAndroid Build Coastguard Worker <td><strong>formatting<br/>locale</strong></td> 904*912701f9SAndroid Build Coastguard Worker <td><strong>order</strong></td> 905*912701f9SAndroid Build Coastguard Worker <td><strong>foreign<br/>space</strong></td> 906*912701f9SAndroid Build Coastguard Worker </tr> 907*912701f9SAndroid Build Coastguard Worker <tr> 908*912701f9SAndroid Build Coastguard Worker <td>de_Latn_CH</td> 909*912701f9SAndroid Build Coastguard Worker <td>Albert</td> 910*912701f9SAndroid Build Coastguard Worker <td>Einstein</td> 911*912701f9SAndroid Build Coastguard Worker <td>YES</td> 912*912701f9SAndroid Build Coastguard Worker <td>de</td> 913*912701f9SAndroid Build Coastguard Worker <td>given First</td> 914*912701f9SAndroid Build Coastguard Worker <td></td> 915*912701f9SAndroid Build Coastguard Worker </tr> 916*912701f9SAndroid Build Coastguard Worker <tr> 917*912701f9SAndroid Build Coastguard Worker <td colspan="7" style="text-align:center">“Albert Einstein”</td> 918*912701f9SAndroid Build Coastguard Worker </tr> 919*912701f9SAndroid Build Coastguard Worker <tr> 920*912701f9SAndroid Build Coastguard Worker <td>de_Jpan_CH</td> 921*912701f9SAndroid Build Coastguard Worker <td>アルベルト</td> 922*912701f9SAndroid Build Coastguard Worker <td>アインシュタイン</td> 923*912701f9SAndroid Build Coastguard Worker <td>NO</td> 924*912701f9SAndroid Build Coastguard Worker <td>ja<br/>from script</td> 925*912701f9SAndroid Build Coastguard Worker <td>given First</td> 926*912701f9SAndroid Build Coastguard Worker <td>“<span style="background-color:aqua">・</span>”</td> 927*912701f9SAndroid Build Coastguard Worker </tr> 928*912701f9SAndroid Build Coastguard Worker <tr> 929*912701f9SAndroid Build Coastguard Worker <td colspan="7" style="text-align:center">“アルベルト<span style="background-color:aqua">・</span>アインシュタイン”</td> 930*912701f9SAndroid Build Coastguard Worker </tr> 931*912701f9SAndroid Build Coastguard Worker <tr> 932*912701f9SAndroid Build Coastguard Worker <td>und_Latn_JP</td> 933*912701f9SAndroid Build Coastguard Worker <td>Hayao</td> 934*912701f9SAndroid Build Coastguard Worker <td>Miyazaki</td> 935*912701f9SAndroid Build Coastguard Worker <td>YES</td> 936*912701f9SAndroid Build Coastguard Worker <td>und</td> 937*912701f9SAndroid Build Coastguard Worker <td>given First</td> 938*912701f9SAndroid Build Coastguard Worker <td>“<span style="background-color:aqua"> </span>”</td> 939*912701f9SAndroid Build Coastguard Worker </tr> 940*912701f9SAndroid Build Coastguard Worker <tr> 941*912701f9SAndroid Build Coastguard Worker <td colspan="7" style="text-align:center">“Hayao<span style="background-color:aqua"> </span>Miyazaki”</td> 942*912701f9SAndroid Build Coastguard Worker </tr> 943*912701f9SAndroid Build Coastguard Worker</table> 944*912701f9SAndroid Build Coastguard Worker<br/> 945*912701f9SAndroid Build Coastguard Worker 946*912701f9SAndroid Build Coastguard Worker### Formatting examples 947*912701f9SAndroid Build Coastguard Worker 948*912701f9SAndroid Build Coastguard WorkerThe personName element contains: 949*912701f9SAndroid Build Coastguard Worker 950*912701f9SAndroid Build Coastguard Worker 951*912701f9SAndroid Build Coastguard Worker> `<namePattern>{title} {given} {given2} {surname}, {credentials}</namePattern>` 952*912701f9SAndroid Build Coastguard Worker 953*912701f9SAndroid Build Coastguard Worker 954*912701f9SAndroid Build Coastguard WorkerThe input PersonName object contains: 955*912701f9SAndroid Build Coastguard Worker 956*912701f9SAndroid Build Coastguard Worker| `title` | `given` | `given2` | `surname` | `generation` | 957*912701f9SAndroid Build Coastguard Worker| -------- | ------- | -------- | --------- | -------- | 958*912701f9SAndroid Build Coastguard Worker| | Raymond | J. | Johnson | Jr. | 959*912701f9SAndroid Build Coastguard Worker 960*912701f9SAndroid Build Coastguard WorkerThe output is: 961*912701f9SAndroid Build Coastguard Worker 962*912701f9SAndroid Build Coastguard Worker> Raymond J. Johnson, Jr. 963*912701f9SAndroid Build Coastguard Worker 964*912701f9SAndroid Build Coastguard WorkerThe “title” field is empty, and so both it and the space that follows it are omitted from the output, according to rule 1 above. 965*912701f9SAndroid Build Coastguard Worker 966*912701f9SAndroid Build Coastguard WorkerIf, instead, the input PersonName object contains: 967*912701f9SAndroid Build Coastguard Worker 968*912701f9SAndroid Build Coastguard Worker| `title` | `given` | `given2` | `surname` | `generation` | 969*912701f9SAndroid Build Coastguard Worker| -------- | ------- | -------- | --------- | -------- | 970*912701f9SAndroid Build Coastguard Worker| | Raymond | J. | Johnson | | 971*912701f9SAndroid Build Coastguard Worker 972*912701f9SAndroid Build Coastguard WorkerThe output is: 973*912701f9SAndroid Build Coastguard Worker 974*912701f9SAndroid Build Coastguard Worker> Raymond J. Johnson 975*912701f9SAndroid Build Coastguard Worker 976*912701f9SAndroid Build Coastguard WorkerThe “title” field is empty, and so both it and the space that follows it are omitted from the output, according to rule 1 above. 977*912701f9SAndroid Build Coastguard Worker 978*912701f9SAndroid Build Coastguard WorkerThe “generation” field is also empty, so it and both the comma and the space that precede it are omitted from the output, according to rule 2 above. 979*912701f9SAndroid Build Coastguard Worker 980*912701f9SAndroid Build Coastguard WorkerTo see how rule 3 interacts with the other rules, consider an imaginary language in which people generally have given and given2 (or middle) names, and the given2 name is always written with parentheses around it, and the given name is usually written as an initial with a following period. 981*912701f9SAndroid Build Coastguard Worker 982*912701f9SAndroid Build Coastguard WorkerThe personName element contains: 983*912701f9SAndroid Build Coastguard Worker 984*912701f9SAndroid Build Coastguard Worker> `<namePattern>{given-initial}. ({given2}) {surname}</namePattern>` 985*912701f9SAndroid Build Coastguard Worker 986*912701f9SAndroid Build Coastguard Worker 987*912701f9SAndroid Build Coastguard WorkerThe input PersonName object contains: 988*912701f9SAndroid Build Coastguard Worker 989*912701f9SAndroid Build Coastguard Worker| `given` | `given2` | `surname` | 990*912701f9SAndroid Build Coastguard Worker| ------- | -------- | --------- | 991*912701f9SAndroid Build Coastguard Worker| Foo | Bar | Baz | 992*912701f9SAndroid Build Coastguard Worker 993*912701f9SAndroid Build Coastguard WorkerThe output is: 994*912701f9SAndroid Build Coastguard Worker 995*912701f9SAndroid Build Coastguard Worker> F. (Bar) Baz 996*912701f9SAndroid Build Coastguard Worker 997*912701f9SAndroid Build Coastguard WorkerIf, instead, the input PersonName object contains: 998*912701f9SAndroid Build Coastguard Worker 999*912701f9SAndroid Build Coastguard Worker| `given` | `given2` | `surname` | 1000*912701f9SAndroid Build Coastguard Worker| ------- | -------- | --------- | 1001*912701f9SAndroid Build Coastguard Worker| Foo | | Baz | 1002*912701f9SAndroid Build Coastguard Worker 1003*912701f9SAndroid Build Coastguard WorkerThe output is: 1004*912701f9SAndroid Build Coastguard Worker 1005*912701f9SAndroid Build Coastguard Worker> F. Baz 1006*912701f9SAndroid Build Coastguard Worker 1007*912701f9SAndroid Build Coastguard WorkerThe “given2” field is empty, so it and the surrounding parentheses are omitted from the output, as is one of the surrounding spaces, according to rule 3. The period after “{given-initial}” remains, because it is separated from the “{given2}” element by space-- punctuation around a missing field is only deleted up until the closest space in each direction. 1008*912701f9SAndroid Build Coastguard Worker 1009*912701f9SAndroid Build Coastguard WorkerIf there were no space between the period and the parentheses, as might happen if our hypothetical language didn’t use spaces: 1010*912701f9SAndroid Build Coastguard Worker 1011*912701f9SAndroid Build Coastguard Worker> `<namePattern>{given-initial}.({given2}) {surname}</namePattern>` 1012*912701f9SAndroid Build Coastguard Worker 1013*912701f9SAndroid Build Coastguard WorkerThe input PersonName object still contains: 1014*912701f9SAndroid Build Coastguard Worker 1015*912701f9SAndroid Build Coastguard Worker| `given` | `given2` | `surname` | 1016*912701f9SAndroid Build Coastguard Worker| ------- | -------- | --------- | 1017*912701f9SAndroid Build Coastguard Worker| Foo | | Baz | 1018*912701f9SAndroid Build Coastguard Worker 1019*912701f9SAndroid Build Coastguard WorkerThe output is: 1020*912701f9SAndroid Build Coastguard Worker 1021*912701f9SAndroid Build Coastguard Worker> F Baz 1022*912701f9SAndroid Build Coastguard Worker 1023*912701f9SAndroid Build Coastguard WorkerBoth the period after “{given-initial}” _and_ the parentheses around “{given2}” are omitted from the output, because there was no space between them — instead, we delete punctuation all the way up to the neighboring field. To solve this (making sure the “{given-initial}” field always has a period after it), you would add another namePattern: 1024*912701f9SAndroid Build Coastguard Worker 1025*912701f9SAndroid Build Coastguard Worker> `<namePattern>{given-initial}.({given2}) {surname}</namePattern>`<br/> 1026*912701f9SAndroid Build Coastguard Worker> `<namePattern alt=”2”>{given-initial}. {surname}</namePattern>` 1027*912701f9SAndroid Build Coastguard Worker 1028*912701f9SAndroid Build Coastguard WorkerThe first pattern would be used when the “given2” field is populated, and the second pattern would be used when the “given2” field is empty. 1029*912701f9SAndroid Build Coastguard Worker 1030*912701f9SAndroid Build Coastguard WorkerRules 1 and 3 can conflict in similar ways. If the personName element contains (there’s a space between the period and the opening parenthesis again): 1031*912701f9SAndroid Build Coastguard Worker 1032*912701f9SAndroid Build Coastguard Worker> `<namePattern>{given-initial}. ({given2}) {surname}</namePattern>` 1033*912701f9SAndroid Build Coastguard Worker 1034*912701f9SAndroid Build Coastguard WorkerAnd the input PersonName object contains: 1035*912701f9SAndroid Build Coastguard Worker 1036*912701f9SAndroid Build Coastguard Worker| `given` | `given2` | `surname` | 1037*912701f9SAndroid Build Coastguard Worker| ------- | -------- | --------- | 1038*912701f9SAndroid Build Coastguard Worker| | Bar | Baz | 1039*912701f9SAndroid Build Coastguard Worker 1040*912701f9SAndroid Build Coastguard WorkerThe output is: 1041*912701f9SAndroid Build Coastguard Worker 1042*912701f9SAndroid Build Coastguard Worker> Bar) Baz 1043*912701f9SAndroid Build Coastguard Worker 1044*912701f9SAndroid Build Coastguard WorkerBecause the “given” field is empty, rule 1 not only has us delete it, but also all punctuation up to “{given2}”. This includes _both_ the period _and_ the opening parenthesis. Again, to solve this, you’d supply two namePatterns: 1045*912701f9SAndroid Build Coastguard Worker 1046*912701f9SAndroid Build Coastguard Worker> `<namePattern>{given-initial}. ({given2}) {surname}</namePattern>`<br/> 1047*912701f9SAndroid Build Coastguard Worker> `<namePattern alt=”2”> ({given2}) {surname}</namePattern>` 1048*912701f9SAndroid Build Coastguard Worker 1049*912701f9SAndroid Build Coastguard WorkerThe output would then be: 1050*912701f9SAndroid Build Coastguard Worker 1051*912701f9SAndroid Build Coastguard Worker> (Bar) Baz 1052*912701f9SAndroid Build Coastguard Worker 1053*912701f9SAndroid Build Coastguard WorkerThe first namePattern would be used if the “given” field was populated, and the second would be used if it was empty. 1054*912701f9SAndroid Build Coastguard Worker 1055*912701f9SAndroid Build Coastguard WorkerIf, instead, the input PersonName object contains: 1056*912701f9SAndroid Build Coastguard Worker 1057*912701f9SAndroid Build Coastguard Worker| `given` | `given2` | `surname` | 1058*912701f9SAndroid Build Coastguard Worker| ------- | -------- | --------- | 1059*912701f9SAndroid Build Coastguard Worker| Foo | | Baz | 1060*912701f9SAndroid Build Coastguard Worker 1061*912701f9SAndroid Build Coastguard WorkerThe output is: 1062*912701f9SAndroid Build Coastguard Worker 1063*912701f9SAndroid Build Coastguard Worker> F. Baz 1064*912701f9SAndroid Build Coastguard Worker 1065*912701f9SAndroid Build Coastguard Worker## Sample Name 1066*912701f9SAndroid Build Coastguard Worker 1067*912701f9SAndroid Build Coastguard WorkerThe sampleName element is used for test names in the personNames LDML data for each locale to aid in testing and display in the CLDR Survey Tool. They are not intended to be used in production software as prompts or placeholders in a user interface and should not be displayed in a user interface. 1068*912701f9SAndroid Build Coastguard Worker 1069*912701f9SAndroid Build Coastguard Worker### Syntax 1070*912701f9SAndroid Build Coastguard Worker 1071*912701f9SAndroid Build Coastguard Worker```xml 1072*912701f9SAndroid Build Coastguard Worker<!ELEMENT sampleName ( nameField+ ) > 1073*912701f9SAndroid Build Coastguard Worker<!ATTLIST sampleName item NMTOKEN #REQUIRED > 1074*912701f9SAndroid Build Coastguard Worker``` 1075*912701f9SAndroid Build Coastguard Worker 1076*912701f9SAndroid Build Coastguard Worker* `NMTOKEN` must be one of `( nativeG, nativeGS, nativeGGS, nativeFull, foreignG, foreignGS, foreignGGS, foreignFull )`. However, these may change arbitrarily in the future. 1077*912701f9SAndroid Build Coastguard Worker 1078*912701f9SAndroid Build Coastguard Worker### Expected values 1079*912701f9SAndroid Build Coastguard Worker 1080*912701f9SAndroid Build Coastguard WorkerThe item values starting with "native" are expected to be native names, in native script. 1081*912701f9SAndroid Build Coastguard WorkerThe item values starting with "foreign" are expected to be foreign names, in native script. 1082*912701f9SAndroid Build Coastguard WorkerThere are no foreign names or native names in a foreign script, because those should be handled by a different locale's data. 1083*912701f9SAndroid Build Coastguard Worker 1084*912701f9SAndroid Build Coastguard WorkerThe rest of the item value indicates how many fields are present. 1085*912701f9SAndroid Build Coastguard WorkerFor the expected sample name items, assume a name such as Mr. Richard “Rich” Edward Smith Iglesias Ph.D. 1086*912701f9SAndroid Build Coastguard Worker 1087*912701f9SAndroid Build Coastguard Worker* `G` is for an example name with only the given is presented: “Richard” or “Rich” (informal) 1088*912701f9SAndroid Build Coastguard Worker* `GS` is for an example name with only the given name and surname: “Richard Smith” or “Rich Smith” (informal) 1089*912701f9SAndroid Build Coastguard Worker* `GSS` is for an example using both given and given2 names and a surname: “Richard Edward Smith” and “Rich E. Smith” (informal) 1090*912701f9SAndroid Build Coastguard Worker* `Full` is used to present a name using all possible fields: “Mr. Richard Edward Smith Iglesias, Ph.D.” 1091*912701f9SAndroid Build Coastguard Worker 1092*912701f9SAndroid Build Coastguard WorkerThe `nameField` values and their modifiers are described in the [Person Name Object](#person-name-object) and [namePattern Syntax](#namepattern-syntax) sections. 1093*912701f9SAndroid Build Coastguard Worker 1094*912701f9SAndroid Build Coastguard Worker## PersonName Data Interface Examples 1095*912701f9SAndroid Build Coastguard Worker 1096*912701f9SAndroid Build Coastguard Worker### Example 1 1097*912701f9SAndroid Build Coastguard Worker 1098*912701f9SAndroid Build Coastguard WorkerGreek initials can be produced via the following process in the PersonName object, and returned to the formatter. 1099*912701f9SAndroid Build Coastguard Worker 1100*912701f9SAndroid Build Coastguard Worker* Include all letters up through the first consonant or digraph (including the consonant or digraph).<br/> 1101*912701f9SAndroid Build Coastguard Worker(This is a simplified version of the actual process.) 1102*912701f9SAndroid Build Coastguard Worker 1103*912701f9SAndroid Build Coastguard WorkerExamples: 1104*912701f9SAndroid Build Coastguard Worker 1105*912701f9SAndroid Build Coastguard Worker* Χριστίνα Λόπεζ (Christina Lopez) ⟶ Χ. Λόπεζ (C. Lopez) 1106*912701f9SAndroid Build Coastguard Worker* Ντέιβιντ Λόπεζ (David Lopez) ⟶ Ντ. Λόπεζ (D. Lopez)<br/>Note that Ντ is a digraph representing the sound D. 1107*912701f9SAndroid Build Coastguard Worker 1108*912701f9SAndroid Build Coastguard Worker### Example 2 1109*912701f9SAndroid Build Coastguard Worker 1110*912701f9SAndroid Build Coastguard WorkerTo make an initial when there are multiple words, an implementation might produce the following: 1111*912701f9SAndroid Build Coastguard Worker 1112*912701f9SAndroid Build Coastguard Worker* A field containing multiple words might skip some of them, such as in “Mohammed bin Ali bin Osman” (“MAO”). 1113*912701f9SAndroid Build Coastguard Worker* The short version of "Son Heung-min" is "H. Son" and not "H. M. Son" or the like. Korean given-names have hyphens and the part after the hyphen is lower-case. 1114*912701f9SAndroid Build Coastguard Worker 1115*912701f9SAndroid Build Coastguard Worker 1116*912701f9SAndroid Build Coastguard Worker* * * 1117*912701f9SAndroid Build Coastguard Worker 1118*912701f9SAndroid Build Coastguard WorkerCopyright © 2001–2024 Unicode, Inc. All Rights Reserved. The Unicode Consortium makes no expressed or implied warranty of any kind, and assumes no liability for errors or omissions. No liability is assumed for incidental and consequential damages in connection with or arising out of the use of the information or programs contained or accompanying this technical report. The Unicode [Terms of Use](https://www.unicode.org/copyright.html) apply. 1119*912701f9SAndroid Build Coastguard Worker 1120*912701f9SAndroid Build Coastguard WorkerUnicode and the Unicode logo are trademarks of Unicode, Inc., and are registered in some jurisdictions. 1121