Package com.google.genai.types
Class LatLng
-
- All Implemented Interfaces:
public abstract class LatLng extends JsonSerializable
An object that represents a latitude/longitude pair.
This is expressed as a pair of doubles to represent degrees latitude and degrees longitude. Unless specified otherwise, this object must conform to the WGS84 standard. Values must be within normalized ranges.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public abstract classLatLng.BuilderBuilder for LatLng.
-
Field Summary
Fields Modifier and Type Field Description public final static StringMAX_READ_LENGTH_PROPERTY
-
Constructor Summary
Constructors Constructor Description LatLng()
-
Method Summary
Modifier and Type Method Description abstract Optional<Double>latitude()The latitude in degrees. abstract Optional<Double>longitude()The longitude in degrees. static LatLng.Builderbuilder()Instantiates a builder for LatLng. abstract LatLng.BuildertoBuilder()Creates a builder with the same values as this instance. static LatLngfromJson(String jsonString)Deserializes a JSON string to a LatLng object. -
Methods inherited from class com.google.genai.JsonSerializable
fromJsonNode, fromJsonString, objectMapper, setMaxReadLength, stringToJsonNode, toJson, toJsonNode, toJsonString -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
latitude
abstract Optional<Double> latitude()
The latitude in degrees. It must be in the range [-90.0, +90.0].
-
longitude
abstract Optional<Double> longitude()
The longitude in degrees. It must be in the range [-180.0, +180.0]
-
builder
static LatLng.Builder builder()
Instantiates a builder for LatLng.
-
toBuilder
abstract LatLng.Builder toBuilder()
Creates a builder with the same values as this instance.
-
-
-
-