UNPKG

trclib

Version:

Client and utility wrappers for TRC rest APIs

23 lines (22 loc) 622 B
export interface IGeoPoint { Lat: number; Long: number; } export interface IGpsTracker { getLocation(): IGeoPoint; } export declare class MockGpsTracker implements IGpsTracker { private _geo; getLocation(): IGeoPoint; setLocation(geo: IGeoPoint): void; } export declare class GpsTracker implements IGpsTracker { private _watchId; private _lastGeo; private _callback; start(callback: (loc: IGeoPoint) => void): void; private static errorCallback(pthis); private static successCallback(pthis, position); getLocation(): IGeoPoint; stop(): void; }