Package org.webkitgtk
Class GeolocationPosition
java.lang.Object
org.javagi.base.ProxyInstance
org.webkitgtk.GeolocationPosition
- All Implemented Interfaces:
Proxy
An opaque struct to provide position updates to a
WebKitGeolocationManager.
WebKitGeolocationPosition is an opaque struct used to provide position updates to a
WebKitGeolocationManager using webkit_geolocation_manager_update_position().
- Since:
- 2.26
-
Constructor Summary
ConstructorsConstructorDescriptionGeolocationPosition(double latitude, double longitude, double accuracy) Create a newWebKitGeolocationPosition.GeolocationPosition(MemorySegment address) Create a GeolocationPosition proxy instance for the provided memory address. -
Method Summary
Modifier and TypeMethodDescriptioncopy()Make a copy of theWebKitGeolocationPosition.voidfree()Free theWebKitGeolocationPositionstatic @Nullable TypegetType()Get the GType of the GeolocationPosition classvoidsetAltitude(double altitude) Set the this GeolocationPosition altitude.voidsetAltitudeAccuracy(double altitudeAccuracy) Set the accuracy of this GeolocationPosition altitude.voidsetHeading(double heading) Set the this GeolocationPosition heading.voidsetSpeed(double speed) Set the this GeolocationPosition speed.voidsetTimestamp(long timestamp) Set the this GeolocationPosition timestamp.Methods inherited from class org.javagi.base.ProxyInstance
equals, handle, hashCode
-
Constructor Details
-
GeolocationPosition
Create a GeolocationPosition proxy instance for the provided memory address.- Parameters:
address- the memory address of the native object
-
GeolocationPosition
public GeolocationPosition(double latitude, double longitude, double accuracy) Create a newWebKitGeolocationPosition.- Parameters:
latitude- a valid latitude in degreeslongitude- a valid longitude in degreesaccuracy- accuracy of location in meters- Since:
- 2.26
-
-
Method Details
-
getType
Get the GType of the GeolocationPosition class- Returns:
- the GType
-
copy
Make a copy of theWebKitGeolocationPosition.- Returns:
- a copy of this GeolocationPosition
- Since:
- 2.26
-
free
public void free()Free theWebKitGeolocationPosition- Since:
- 2.26
-
setAltitude
public void setAltitude(double altitude) Set the this GeolocationPosition altitude.- Parameters:
altitude- altitude in meters- Since:
- 2.26
-
setAltitudeAccuracy
public void setAltitudeAccuracy(double altitudeAccuracy) Set the accuracy of this GeolocationPosition altitude.- Parameters:
altitudeAccuracy- accuracy of position altitude in meters- Since:
- 2.26
-
setHeading
public void setHeading(double heading) Set the this GeolocationPosition heading.Set the this GeolocationPosition heading, as a positive angle between the direction of movement and the North direction, in clockwise direction.
- Parameters:
heading- heading in degrees- Since:
- 2.26
-
setSpeed
public void setSpeed(double speed) Set the this GeolocationPosition speed.- Parameters:
speed- speed in meters per second- Since:
- 2.26
-
setTimestamp
public void setTimestamp(long timestamp) Set the this GeolocationPosition timestamp.By default it's the time when the this GeolocationPosition was created.
- Parameters:
timestamp- timestamp in seconds since the epoch, or 0 to use current time- Since:
- 2.26
-