GeostoreNameProto

GoogleApi.ContentWarehouse.V1.Model.GeostoreNameProto


Table of Contents ▼

Jump to a specific part of the page:

Description

A name for a Feature (street name, point of interest, city, building, etc). We currently use NameProto for two essentially disjoint purposes: 1. Common names, which can be language-specific, or have other kinds of variations. 2. Opaque IDs, such as postal codes, which only have the text field set, and potentially some flags. This includes internal-only features like template ids. Each NameProto representing a common name corresponds to an assertion that a fluent speaker or writer of a language would recognize NameProto.text to name the given feature in that language. As such, NameProtos are stored in a repeated field, often having: 1. multiple names with the same text and varying languages, and 2. multiple names with the same language and varying texts.

Attributes List

This module has the following attributes (case-insensitive ascending order):

View Attributes

Attributes

  1. flag (type: list(String.t), default: nil)
    - clang-format on The set of flags that apply to this name.
  2. language (type: String.t, default: nil)
    - The external form of a Google International Identifiers Initiative (III) LanguageCode object. See google3/i18n/identifiers/languagecode.h for details. These strings should be treated as opaque blobs. You can use LanguageCodeConverter::FromOther to convert the string to a LanguageCode reference. You can then call methods on the LanguageCode class to extract language/script/region subtags (if any). See also http://g3doc/i18n/identifiers/g3doc/using-iii. We place extra restrictions on languages in addition to what the III library requires. See go/geo-schema-reference/feature-properties/languages. This field may be missing if the name does not have a concept of language but should be set if the language is unknown.
  3. metadata (type: GoogleApi.ContentWarehouse.V1.Model.GeostoreFieldMetadataProto, default: nil)
    - Field-level metadata for this name. NOTE: there are multiple NameProto fields in the Geo Schema. Metadata here is only expected to be present on FeatureProto.name[].
  4. rawText (type: String.t, default: nil)
    - DEPRECATED The name text provided in the original source data (UTF-8 encoding). This is the text provided in the source data unmodified with the exception of being converted to UTF-8 and stripping extra leading, trailing and duplicate whitespaces (if necessary).
  5. shortText (type: String.t, default: nil)
    - The short name text (UTF-8 encoding). Acronyms/abbreviations should be consistently used, for example "NE 57th St" rather than "Northeast 57th Street", "N.E 57th St." or some other variant. This field should be populated with the chosen canonical version of the shortened name, based on per-term transformations. For feature specific abbreviations (such as 'CA' for 'California'), one should define a separate name with FLAG_ABBREVIATED set. For other variants of the shortened name that are not the canonical one, devise client based logic (ex: query rewriting rules).
  6. temporaryData (type: GoogleApi.ContentWarehouse.V1.Model.Proto2BridgeMessageSet, default: nil)
    - A place for clients to attach arbitrary data to a name. Never set in MapFacts.
  7. text (type: String.t, default: nil)
    - The name text (UTF-8 encoding). Acronyms/abbreviations should be fully expanded, for example "Northeast 57th Street" rather than "NE 57th St". They can be shortened at display or geocode time. This decision prevents ambiguity over such issues as whether "St" represents "Street" or "Saint". However, it pushes language-specific knowledge into code. We will have libraries and data files to contract acronyms/abbreviations at run-time.

Type

@type t() :: %GoogleApi.ContentWarehouse.V1.Model.GeostoreNameProto{
flag: [String.t()] | nil,
language: String.t() | nil,
metadata: GoogleApi.ContentWarehouse.V1.Model.GeostoreFieldMetadataProto.t() | nil,
rawText: String.t() | nil,
shortText: String.t() | nil,
temporaryData: GoogleApi.ContentWarehouse.V1.Model.Proto2BridgeMessageSet.t() | nil,
text: String.t() | nil
}

Function

@spec decode(struct(), keyword()) :: struct()

Data sourced from HexDocs : GoogleApi.ContentWarehouse.V1.Model.GeostoreNameProto