Landmark

public abstract class Landmark implements Parcelable


Basic landmark information and the landmark's relationship with the target location.

Landmarks are prominent places that can be used to describe a location.

Summary

Nested types

public abstract class Landmark.Builder

A builder to create instances of Landmark.

Defines the spatial relationship between the target location and the landmark.

Public constructors

Public methods

static Landmark.Builder

Returns a new instance of Builder.

abstract @Nullable String

The landmark's display name.

abstract @Nullable String

The landmark's display name language code.

abstract @Nullable String

The landmark's Place ID.

abstract @Nullable String

The landmark's resource name.

abstract @Nullable Landmark.SpatialRelationship

Defines the spatial relationship between the target location and the landmark.

abstract @Nullable Double

The straight line distance, in meters, between the center point of the target and the center point of the landmark.

abstract @Nullable Double

The travel distance, in meters, along the road network from the target to the landmark, if known.

abstract @Nullable List<String>

A set of type tags for this landmark.

Inherited Constants

From android.os.Parcelable
static final int
static final int
static final int
static final int

Inherited methods

From android.os.Parcelable
abstract int
int
abstract void
writeToParcel(Parcel p, int p1)

Public constructors

Landmark

public Landmark()

Public methods

builder

public static Landmark.Builder builder()

Returns a new instance of Builder.

getDisplayName

public abstract @Nullable String getDisplayName()

The landmark's display name.

getDisplayNameLanguageCode

public abstract @Nullable String getDisplayNameLanguageCode()

The landmark's display name language code.

getId

public abstract @Nullable String getId()

The landmark's Place ID.

getResourceName

public abstract @Nullable String getResourceName()

The landmark's resource name.

getSpatialRelationship

public abstract @Nullable Landmark.SpatialRelationship getSpatialRelationship()

Defines the spatial relationship between the target location and the landmark.

getStraightLineDistanceMeters

public abstract @Nullable Double getStraightLineDistanceMeters()

The straight line distance, in meters, between the center point of the target and the center point of the landmark. In some situations, this value can be longer than getTravelDistanceMeters.

getTravelDistanceMeters

public abstract @Nullable Double getTravelDistanceMeters()

The travel distance, in meters, along the road network from the target to the landmark, if known. This value does not take into account the mode of transportation, such as walking, driving, or biking.

getTypes

public abstract @Nullable List<StringgetTypes()

A set of type tags for this landmark. For a complete list of possible values, see https://developers.google.com/maps/documentation/places/web-service/place-types.