public class GeoPoint implements Serializable
Immutable class representing a geographic location in Firestore
Implements
SerializableConstructors
GeoPoint(double latitude, double longitude)
public GeoPoint(double latitude, double longitude)
Construct a new GeoPoint using the provided latitude and longitude values.
Name | Description |
latitude | double The latitude of this GeoPoint in the range [-90, 90]. |
longitude | double The longitude of this GeoPoint in the range [-180, 180]. |
Methods
equals(Object obj)
public boolean equals(Object obj)
Returns true if this GeoPoint is equal to the provided object.
Name | Description |
obj | Object The object to compare against. |
Type | Description |
boolean | Whether this GeoPoint is equal to the provided object. |
getLatitude()
public double getLatitude()
Returns the latitude.
Type | Description |
double | The latitude value of this GeoPoint. |
getLongitude()
public double getLongitude()
Returns the longitude.
Type | Description |
double | The longitude value of this GeoPoint. |
hashCode()
public int hashCode()
Type | Description |
int |
toString()
public String toString()
Type | Description |
String |