- Timestamp:
- 04/15/09 14:50:04 (17 months ago)
- Location:
- tools/routingservice/branches/wrs-2.0
- Files:
-
- 1 added
- 6 modified
-
data/resources.xml (modified) (1 diff)
-
data/services.xml (modified) (2 diffs)
-
data/templates/catch/catch_kml.st (modified) (2 diffs)
-
data/templates/route/route_kml.st (modified) (1 diff)
-
src/WRS.java (modified) (2 diffs)
-
src/util/format/FillerFactory.java (modified) (1 diff)
-
src/util/format/KMLTemplateFiller.java (added)
Legend:
- Unmodified
- Added
- Removed
-
tools/routingservice/branches/wrs-2.0/data/resources.xml
r294 r295 4 4 <resource type="database" name="pgrouting" 5 5 title="pgRouting instance on Dumbo server"> 6 <description> My test profile I use for testing</description>6 <description>pgRouting 1.0.1, PostGIS 1.11, PostgreSQL 8.1</description> 7 7 <parameters> 8 8 <parameter name="srid" type="integer" key="srid" value="4326" /> -
tools/routingservice/branches/wrs-2.0/data/services.xml
r294 r295 6 6 <templates> 7 7 <template name="gml" format="xml" url="./data/templates/route/route_gml.st"/> 8 <template name="kml" format="xml" url="./data/templates/route/route_kml.st"/> 8 9 </templates> 9 10 <in> … … 22 23 <description>Returns a polygon representing a catchment area for going from point A within distance D</description> 23 24 <templates> 24 <template name="kml" format="xml" url="./data/templates/ route/route_kml.st"/>25 <template name="kml" format="xml" url="./data/templates/catch/catch_kml.st"/> 25 26 </templates> 26 27 <in> -
tools/routingservice/branches/wrs-2.0/data/templates/catch/catch_kml.st
r284 r295 23 23 <description></description> 24 24 <styleUrl>#polygonStyle</styleUrl> 25 25 26 $parameters:{ p | 26 27 <Polygon> 27 28 <tessellate>1</tessellate> … … 29 30 <outerBoundaryIs> 30 31 <LinearRing> 31 <coordinates>$poly$</coordinates> 32 <coordinates> 33 $p.polygon$ 34 </coordinates> 32 35 </LinearRing> 33 36 </outerBoundaryIs> 34 37 </Polygon> 35 38 }$ 36 39 <ExtendedData> 37 40 <wrs:status> -
tools/routingservice/branches/wrs-2.0/data/templates/route/route_kml.st
r284 r295 20 20 21 21 <MultiGeometry> 22 $ edges:{ e|23 <LineString id="$ e.id$">22 $parameters:{ p | 23 <LineString id="$p.id$"> 24 24 <tessellate>1</tessellate> 25 25 <altitudeMode>clampToGround</altitudeMode> 26 26 <coordinates> 27 $ e.points:{ p |$p.x$,$p.y$,0};separator=" "$27 $p.line$ 28 28 </coordinates> 29 29 </LineString> -
tools/routingservice/branches/wrs-2.0/src/WRS.java
r294 r295 212 212 } 213 213 } 214 214 215 String templateType = serviceRequest.getTemplate().getFormat(); 216 response.setEntity(result, MIMETypes.valueOf( 217 templateType.toUpperCase()).getType()); 215 218 } 216 219 catch (InvalidVersionException e) … … 244 247 response.setStatus(Status.CLIENT_ERROR_BAD_REQUEST); 245 248 } 246 247 String templateType = serviceRequest.getTemplate().getFormat(); 248 response.setEntity(result, MIMETypes.valueOf( 249 templateType.toUpperCase()).getType()); 249 catch (NullPointerException e) 250 { 251 log.logger 252 .warning("Invalid URL. Reqest can't be processed."); 253 response.setStatus(Status.CLIENT_ERROR_BAD_REQUEST); 254 } 255 250 256 } 251 257 }; -
tools/routingservice/branches/wrs-2.0/src/util/format/FillerFactory.java
r294 r295 6 6 public static enum Fillers 7 7 { 8 JSON(null), GEOJSON(null), KML( null), GML(GMLTemplateFiller.class), XLS(9 null), GEORSS(null), GPX(null);8 JSON(null), GEOJSON(null), KML(KMLTemplateFiller.class), GML( 9 GMLTemplateFiller.class), XLS(null), GEORSS(null), GPX(null); 10 10 11 11 private Class<? extends TemplateFiller> fillerType;
