NearestRoad

From CMSC 420
Revision as of 16:54, 30 September 2013 by Rforsythe (talk | contribs) (Created page with "Will output the nearest road to the specified point in the spatial map. Ties will be broken asciibetically by the name of the start then end city. == Parameters (In output or...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Will output the nearest road to the specified point in the spatial map. Ties will be broken asciibetically by the name of the start then end city.

Parameters (In output order)[edit]

  • x
  • y

Possible <output>[edit]

The output will contain one road tag which is the nearest road. This is an example of a road tag:

   <road start="city1" end="city2"/>

Possible <error> types[edit]

  • cityNotFound

<success> Example[edit]

   <success>
       <command name="nearestRoad" id="13">
       <parameters>
           <x value="1"/>
           <y value="2"/>
       </parameters>
       <output>
           <road start="Annapolis" end="Derwood"/>
       </output>
   </success>