HyperTrack

public class HyperTrack

The main entry point for the HyperTrack SDK

Types

Link copied to clipboard
public final class Cancellable
Link copied to clipboard
public class Error
Link copied to clipboard
public final class Location
Link copied to clipboard
public class LocationError

The reason for why the SDK doesn't have a fresh location.

Link copied to clipboard
public final class LocationWithDeviation

Geotag location with deviation from expected location in meters.

Link copied to clipboard
public class OrderStatus

Order event

Functions

Link copied to clipboard
@Deprecated(message = "Use new addGeotag with orderHandle and orderStatus")
final static Result<HyperTrack.Location, HyperTrack.LocationError> addGeotag(Json.Object data)

Adds a new geotag.

@Deprecated(message = "Use new addGeotag with orderHandle and orderStatus")
final static Result<HyperTrack.LocationWithDeviation, HyperTrack.LocationError> addGeotag(Json.Object data, HyperTrack.Location expectedLocation)

Adds a new geotag with expected location.

final static Result<HyperTrack.Location, HyperTrack.LocationError> addGeotag(    String orderHandle,     HyperTrack.OrderStatus orderStatus,     Json.Object metadata)

Adds a new geotag with order status.

final static Result<HyperTrack.LocationWithDeviation, HyperTrack.LocationError> addGeotag(    String orderHandle,     HyperTrack.OrderStatus orderStatus,     Json.Object metadata,     HyperTrack.Location expectedLocation)

Adds a new geotag with expected location and order status.

Link copied to clipboard
final static String getDeviceID()
Link copied to clipboard
final static String getDynamicPublishableKey()
Link copied to clipboard
final static Set<HyperTrack.Error> getErrors()
Link copied to clipboard
final static Result<HyperTrack.Location, HyperTrack.LocationError> getLocation()
Link copied to clipboard
final static Json.Object getMetadata()
Link copied to clipboard
final static String getName()
Link copied to clipboard
final static Boolean isAvailable()
Link copied to clipboard
final static Boolean isTracking()
Link copied to clipboard
final static HyperTrack.Cancellable locate(Function1<Result<HyperTrack.Location, Set<HyperTrack.Error>>, Unit> callback)

Requests one-time location update and returns the location once it is available, or error.

Link copied to clipboard
final Unit registerLocationService(PluginInfo<LocationServices> locationServices)
Link copied to clipboard
final Unit registerPushService(PluginInfo<PushService> pushService)
Link copied to clipboard
final static Unit setAvailable(static Boolean isAvailable)
Link copied to clipboard
final static Unit setDynamicPublishableKey(static String dynamicPublishableKey)
Link copied to clipboard
final static Unit setMetadata(static Json.Object metadata)
Link copied to clipboard
final static Unit setName(static String name)
Link copied to clipboard
final static Unit setTracking(static Boolean isTracking)
Link copied to clipboard
final static HyperTrack.Cancellable subscribeToErrors(Function1<Set<HyperTrack.Error>, Unit> callback)

Subscribe to tracking errors

Link copied to clipboard
final static HyperTrack.Cancellable subscribeToIsAvailable(Function1<Boolean, Unit> callback)

Subscribe to availability changes

Link copied to clipboard
final static HyperTrack.Cancellable subscribeToIsTracking(Function1<Boolean, Unit> callback)

Subscribe to tracking intent changes

Link copied to clipboard
final static HyperTrack.Cancellable subscribeToLocation(Function1<Result<HyperTrack.Location, HyperTrack.LocationError>, Unit> callback)

Subscribe to location changes

Properties

Link copied to clipboard
private final static String deviceID

Returns a string that is used to uniquely identify the device

Link copied to clipboard
private static String dynamicPublishableKey
Link copied to clipboard
private final static Set<HyperTrack.Error> errors

Returns any errors that have occurred in the SDK

Link copied to clipboard
public final static HyperTrack INSTANCE
Link copied to clipboard
private static Boolean isAvailable

Reflects availability of the device for the Nearby search

Link copied to clipboard
private static Boolean isTracking

Reflects the tracking intent for the device

Link copied to clipboard
private final static Result<HyperTrack.Location, HyperTrack.LocationError> location

Reflects the current location of the user or an outage reason

Link copied to clipboard
private static Json.Object metadata

Gets the metadata that is set for the device

Link copied to clipboard
private static String name

Gets the name that is set for the device