public static class GeoLocation.Builder
extends java.lang.Object
GeoLocation.
GeoLocation instance can be obtained using build() method as follows.GeoLocation.Builder builder = GeoLocation.builder();
GeoLocation geoLocation = builder.build();
| Constructor and Description |
|---|
Builder() |
| Modifier and Type | Method and Description |
|---|---|
GeoLocation |
build()
This method is called to build
GeoLocation from the Builder. |
GeoLocation.Builder |
setAccuracy(java.lang.Double accuracy)
Sets accuracy of horizontal GPS error in meters.
|
GeoLocation.Builder |
setAlt(java.lang.Double alt)
Sets Altitude in meters above or below sea level.
|
GeoLocation.Builder |
setAltAccuracy(java.lang.Double altAccuracy)
Sets Vertical GPS error in meters.
|
GeoLocation.Builder |
setArea(java.lang.String area)
Sets a named area such as a campus or neighborhood.
|
GeoLocation.Builder |
setBearing(java.lang.Double bearing)
Sets GPS bearing (direction in which the entity is heading
to reach its next waypoint), measured in decimal degrees, relative to true north. |
GeoLocation.Builder |
setBuilding(java.lang.String building)
Sets a specific building on a street or in an area.
|
GeoLocation.Builder |
setCountry(java.lang.String country)
Sets the nation where the user is located.
|
GeoLocation.Builder |
setCountryCode(java.lang.String countryCode)
Sets The ISO 3166 two-letter country code.
|
GeoLocation.Builder |
setDatum(java.lang.String datum)
Sets GPS Datum.
|
GeoLocation.Builder |
setDescription(java.lang.String description)
Sets A natural-language name for or description of the location.
|
GeoLocation.Builder |
setError(java.lang.Double error)
Deprecated.
use
setAccuracy(Double) instead. |
GeoLocation.Builder |
setFloor(java.lang.String floor)
Sets a particular floor in a building.
|
GeoLocation.Builder |
setLat(java.lang.Double lat)
Sets Latitude in decimal degrees North.
|
GeoLocation.Builder |
setLocality(java.lang.String locality)
Sets Locality within the administrative region,
such as a town or city. |
GeoLocation.Builder |
setLon(java.lang.Double lon)
Sets Longitude in decimal degrees East.
|
GeoLocation.Builder |
setPostalcode(java.lang.String postalcode)
Sets PostalCode used for postal delivery.
|
GeoLocation.Builder |
setRegion(java.lang.String region)
Sets an administrative region of the nation,
such as a state or province. |
GeoLocation.Builder |
setRoom(java.lang.String room)
Sets a particular room in a building.
|
GeoLocation.Builder |
setSpeed(java.lang.Double speed)
Sets Speed at which the entity is moving, in meters per second.
|
GeoLocation.Builder |
setStreet(java.lang.String street)
Sets a thoroughfare within the locality, or a crossing of two thoroughfares.
|
GeoLocation.Builder |
setText(java.lang.String text)
Sets a catch-all element that captures any other information about the location.
|
GeoLocation.Builder |
setTimestamp(java.util.Date timestamp)
Sets UTC timestamp specifying the moment when the reading was taken.
|
GeoLocation.Builder |
setTzo(java.lang.String tzo)
Sets the time zone offset from UTC for the current location.
|
GeoLocation.Builder |
setUri(java.net.URI uri)
Sets URI or URL pointing to information about the location.
|
public GeoLocation.Builder setAccuracy(java.lang.Double accuracy)
accuracy - accuracy in meterspublic GeoLocation.Builder setAlt(java.lang.Double alt)
alt - altitude in meterspublic GeoLocation.Builder setAltAccuracy(java.lang.Double altAccuracy)
altAccuracy - altAccuracy in meterspublic GeoLocation.Builder setArea(java.lang.String area)
area - the named areapublic GeoLocation.Builder setBearing(java.lang.Double bearing)
bearing - bearing in decimal degreespublic GeoLocation.Builder setBuilding(java.lang.String building)
building - name of the buildingpublic GeoLocation.Builder setCountry(java.lang.String country)
country - user's country of locationpublic GeoLocation.Builder setCountryCode(java.lang.String countryCode)
countryCode - two-letter country codepublic GeoLocation.Builder setDatum(java.lang.String datum)
datum - GPS datumpublic GeoLocation.Builder setDescription(java.lang.String description)
description - description of the location@Deprecated public GeoLocation.Builder setError(java.lang.Double error)
setAccuracy(Double) instead.error - error in arc minutespublic GeoLocation.Builder setFloor(java.lang.String floor)
floor - floor in a buildingpublic GeoLocation.Builder setLat(java.lang.Double lat)
lat - latitude in decimal degreespublic GeoLocation.Builder setLocality(java.lang.String locality)
locality - locality in a regionpublic GeoLocation.Builder setLon(java.lang.Double lon)
lon - longitude in decimal degreespublic GeoLocation.Builder setPostalcode(java.lang.String postalcode)
postalcode - code for postal deliverypublic GeoLocation.Builder setRegion(java.lang.String region)
region - an administrative regionpublic GeoLocation.Builder setRoom(java.lang.String room)
room - room inside a buildingpublic GeoLocation.Builder setSpeed(java.lang.Double speed)
speed - speed in meters per secondpublic GeoLocation.Builder setStreet(java.lang.String street)
street - name of the streetpublic GeoLocation.Builder setText(java.lang.String text)
text - distinctive feature about the locationpublic GeoLocation.Builder setTimestamp(java.util.Date timestamp)
timestamp - timestamp of the readingpublic GeoLocation.Builder setTzo(java.lang.String tzo)
tzo - time zone offsetpublic GeoLocation.Builder setUri(java.net.URI uri)
uri - uri to the locationpublic GeoLocation build()
GeoLocation from the Builder.