Class Address

com.yandex.mapkit.search

java.lang.Object ⇽ Address

public class Address

Contains structured address, formatted address, postal code and country code.

Structured address is an ordered list of components (usually administrative hierarchy). Formatted address is a full address as a single string. Formatted address generally can't be obtained from component names. Some components could be ignored (large administrative region) or absent (office number).

Nested Classes

Constructors

Address()

Use constructor with parameters in your code.

Address(@NonNull String formattedAddress, @Nullable String additionalInfo, @Nullable String postalCode, @Nullable String countryCode, @NonNull List< Component > components)

Methods

synchronized String getAdditionalInfo()

Additional address info.

synchronized List< Component > getComponents()

Address component list, see Component, may be empty.

synchronized String getCountryCode()

Country code in ISO 3166-1 alpha-2 format (two-letter country code).

synchronized String getFormattedAddress()

Human-readable address.

String getNativeName()
synchronized String getPostalCode()

Postal/Zip code.

void serialize(Archive archive)

Constructor Detail

Address

public Address ()

Use constructor with parameters in your code.

This one is for serialization only!

Address

public Address (@NonNull String formattedAddress, @Nullable String additionalInfo, @Nullable String postalCode, @Nullable String countryCode, @NonNull List< Component > components)

Method Detail

getAdditionalInfo

public synchronized String getAdditionalInfo ()

Additional address info.

Optional field, can be null.

getComponents

public synchronized List< Component > getComponents ()

Address component list, see Component, may be empty.

getCountryCode

public synchronized String getCountryCode ()

Country code in ISO 3166-1 alpha-2 format (two-letter country code).

Optional field, can be null.

getFormattedAddress

public synchronized String getFormattedAddress ()

Human-readable address.

getNativeName

public static String getNativeName ()

getPostalCode

public synchronized String getPostalCode ()

Postal/Zip code.

Optional field, can be null.

serialize

public void serialize (Archive archive)