GpsGate.Server.GpsTracking
GpsGate Ajax WebService API
| copyright |
Copyright Franson Technology AB - GpsGate.com |
| note |
To be able to use these webmethods you must link to GpsGate.com. See main documentation for details. |
| note |
"NAMESPACE" below will be replaced with the name of your choice when including the service in your page. |
| note |
All methods are asynchronous. I.e the return values are aquired in the callback function. |
Objects
namespace
GpsGate.Server.NAMESPACE
API namespace
methods
- GpsGate.Server.NAMESPACE.getUsersInGroup(groupName, callback)
- GpsGate.Server.NAMESPACE.getUpdatedUsersInGroup(groupName, sinceTime, callback)
- GpsGate.Server.NAMESPACE.getTracksByUser(groupName, username, callback)
- GpsGate.Server.NAMESPACE.getTrackData(groupName, trackId, start, stop, callback)
- GpsGate.Server.NAMESPACE.onError(name, message)
Data Types
User()
properties
| type |
name |
description |
| integer |
id |
the user's unique identifier |
| string |
name |
user's full name |
| string |
username |
user's username in the GpsGate Server system |
| TrackPoint |
trackPoint |
position information. set when loading/updating |
Result_Users()
properties
| type |
name |
description |
| Array[User] |
users |
Array of Users |
| Date |
queryTimeStamp |
time when the data was fetched from the server. to be used when requesting updates |
Position()
properties
| type |
name |
description |
| double |
latitude |
latitude in decimal degrees |
| double |
longitude |
longitude in decimal degrees |
| double |
altitude |
meters |
Velocity()
speed and direction
properties
| type |
name |
description |
| double |
groundSpeed |
m/s |
| double |
heading |
direction in decimal degrees |
TrackPoint()
position and direction information at a specific time
properties
| type |
name |
description |
| Position |
position |
|
| Velocity |
velocity |
|
| Date |
utc |
timestamp |
BoundingBox()
describes extents in space (latitude, longitude, altitude) and time (start, stop)
properties
| type |
name |
description |
| double |
maxX |
|
| double |
minX |
|
| double |
maxY |
|
| double |
minY |
|
| double |
maxZ |
|
| double |
minZ |
|
| Date |
maxTime |
|
| Date |
minTime |
|
TrackInfo()
properties
| type |
name |
description |
| integer |
id |
track's unique identifier |
| string |
name |
|
| integer |
ownerId |
User-id |
| integer |
numPoints |
number of LatLng points in the corresponding TrackData object |
| double |
totalDistance |
length of track in meters |
| BoundingBox |
bounds |
|
Result_TrackInfo()
properties
| type |
name |
description |
| Array[TrackInfo] |
tracks |
Array of TrackInfo objects |
| Date |
queryTimeStamp |
time when the data was aquired from the server |
LatLng()
properties
| type |
name |
description |
| double |
lat |
latitude in decimal degrees |
| double |
lng |
longitude in decimal degrees |
| double |
alt |
altitude. meters |
| Date |
utc |
timestamp |
Result_TrackData()
properties
| type |
name |
description |
| Array[LatLng] |
trackData |
Array of LatLng objects |
| Date |
queryTimeStamp |
time when the data was aquired from the server |
Functions
GpsGate.Server.NAMESPACE.getUsersInGroup(groupName, callback)
Get all users in a group 'groupName'
parameters
| type |
name |
description |
| string |
groupName
|
name of group |
| function(Result_Users) |
callback
|
|
returns
| type |
description |
| void |
asynchronous method, see callback |
GpsGate.Server.NAMESPACE.getUpdatedUsersInGroup(groupName, sinceTime, callback)
parameters
| type |
name |
description |
| string |
groupName
|
name of the group |
| Date |
sinceTime
|
time of the oldest. Typically you should use the .queryTimeStamp returned in the previous update call. |
| function(Result_Users) |
callback
|
|
returns
| type |
description |
| void |
asynchronous method, see callback |
GpsGate.Server.NAMESPACE.getTracksByUser(groupName, username, callback)
Get a user's tracks published in group 'groupName'
parameters
| type |
name |
description |
| string |
groupName
|
group name |
| string |
username
|
user name |
| function(Result_TrackInfo) |
callback
|
|
returns
| type |
description |
| void |
asynchronous method, see callback |
GpsGate.Server.NAMESPACE.getTrackData(groupName, trackId, start, stop, callback)
Get the coordinates of a specific track within a time interval (start->stop)
parameters
| type |
name |
description |
| string |
groupName
|
group name |
| integer |
trackId
|
id of the track to get (see getTracksByUser for |
| Date |
start
|
|
| Date |
stop
|
|
| function(Result_TrackData) |
callback
|
|
returns
| type |
description |
| void |
asynchronous method, see callback |
GpsGate.Server.NAMESPACE.onError(name, message)
Replace this if you need to customize error reporting.
The default behaviour is to show the error + message in an alert box.
parameters
| type |
name |
description |
| string |
name
|
error name |
| string |
message
|
error description |