approved, byrokraatit, ylläpitäjät
0
muokkausta
(→Lines) |
(→Routes) |
||
Rivi 244: | Rivi 244: | ||
} | } | ||
</pre> | </pre> | ||
In addition to its own url, a ROUTE contains url to the LINE under which it is running. ROUTE has a name. ROUTE also has references to JOURNEY PATTERNs and JOURNEYs operating on it. geographicCoordinateProjection contains information on how to draw the route on a map. This field is encoded and the client must decode the fields value. The field takes form: | |||
<pre> | |||
number,number:number,number etc. | |||
</pre> | |||
These are encoded coordinates, in a form of: | |||
<pre> | |||
lat1,lon1:delta lat2,delta lon2:delta lat3,delta lon3 | |||
</pre> | |||
a client would decode the field by following procedure: | |||
A client can search ROUTES by issuing following requests:<br> | A client can search ROUTES by issuing following requests:<br> | ||
* http://data.itsfactory.fi/journeys/api/1/routes will return paged list of all ROUTES | * http://data.itsfactory.fi/journeys/api/1/routes will return paged list of all ROUTES | ||
* http://data.itsfactory.fi/journeys/api/1/routes?lineId=2 will return ROUTES which run on the LINE with id 2 | * http://data.itsfactory.fi/journeys/api/1/routes?lineId=2 will return ROUTES which run on the LINE with id 2 | ||
==== Journeys ==== | ==== Journeys ==== |