• Vidhan's avatar
    [Autofill][States] Implemented AlternativeStateNameMap · bb1e351c
    Vidhan authored
    AlternativeStateNameMap encapsulates mappings from state names in the
    profiles to their localized and the abbreviated version.
    
    AlternativeStateNameMap can provide the following data for the states:
      1. The state string stored in the address profile.
      2. The state canonical name (StateEntry::canonical_name) which acts
         as the unique identifier representing the state. It is used for
         the comparison and determining the mergeability of the address
         profiles.
      3. The abbreviations of the state (StateEntry::abbreviations).
      4. The alternative names of the state (StateEntry::alternative_names).
    
    StateEntry holds the information about the abbreviations and the
    alternative names of the state.
    Example of a StateEntry object:
      {
        'canonical_name': 'California',
        'abbreviations': ['CA'],
        'alternate_names': ['The Golden State']
      }
    
    Bug: 1111960
    Change-Id: I3dc3aa6f9c52c160d179e6dcad646b52b619b9de
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2360274Reviewed-by: default avatarMatthias Körber <koerber@google.com>
    Reviewed-by: default avatarChristoph Schwering <schwering@google.com>
    Reviewed-by: default avatarDominic Battré <battre@chromium.org>
    Commit-Queue: Vidhan Jain <vidhanj@google.com>
    Cr-Commit-Position: refs/heads/master@{#821693}
    bb1e351c
BUILD.gn 28.5 KB