Landmark class

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

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

Documentation: https://developers.google.com/maps/documentation/places/web-service/reference/rest/v1/places#landmark

Inheritance
Available extensions
Annotations
  • @JsonSerializable()
  • @CopyWith()

Constructors

Landmark.new({String? name, String? placeId, LocalizedText? displayName, List<PlaceType>? types, SpatialRelationship? spatialRelationship, double? straightLineDistanceMeters, double? travelDistanceMeters})
Landmark.fromJson(Map<String, dynamic> json)
factory

Properties

copyWith → _$LandmarkCWProxy

Available on Landmark, provided by the $LandmarkCopyWith extension

Returns a callable class that can be used as follows: instanceOfLandmark.copyWith(...).
no setter
displayName LocalizedText?
The landmark's display name.
final
hashCode int
The hash code for this object.
no setterinherited
name String?
The landmark's resource name.
final
placeId String?
The landmark's place id.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
spatialRelationship SpatialRelationship?
Defines the spatial relationship between the target location and the landmark.
final
straightLineDistanceMeters double?
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 travelDistanceMeters.
final
travelDistanceMeters double?
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.
final
types List<PlaceType>?
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. Or PlaceType.values
final

Methods

fromJsonList(List? jsonList) List<Landmark>?
inherited
fromJsonMap(Map<String, dynamic>? json) Landmark?
override
fromJsonString(String? json) Landmark?
inherited
fromJsonStringList(String? jsonStringList) List<Landmark>?
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toFieldsMask({String? parentKey}) List<String>
inherited
toJson() Map<String, dynamic>
override
toJsonMap() Map<String, dynamic>
inherited
toJsonString() String
inherited
toString() String
This is just to suggest children to implement a named constructor to support creating objects fromJson(...) and fromJsonString(...) as easy as T.build().fromJson(...) or T.build().fromJsonString(...)
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited