Anonymous

Changes

From CMSC 420
594 bytes removed ,  01:26, 6 February 2017
Line 1: Line 1:  
'''Part 1''' of the [[MeeshQuest]] project:
 
'''Part 1''' of the [[MeeshQuest]] project:
* Due Date: found on [http://www.cs.umd.edu/class/ class webpage]
+
* Due Date: Either the date on the submit server or the date on the project spec, whichever is later
* All part 1 files can be found [http://www.cs.umd.edu/users/meesh/420/part1/ here]
+
* All part 1 files can be found [https://www.cs.umd.edu/users/meesh/420/ProjectBook/part1/ here]
* The official spec is [http://www.cs.umd.edu/users/meesh/420/part1/ here] with name p1x, for the largest value of x in that directory.  
+
* The official spec is [https://www.cs.umd.edu/users/meesh/420/ProjectBook/part1/p11/ here] with name p1x, for the largest value of x in that directory.  
 
* As always, the spec will freeze 1 week (5 days summer) prior to the due date.
 
* As always, the spec will freeze 1 week (5 days summer) prior to the due date.
 
* [[Part 1 Test Files | Test Files]]
 
* [[Part 1 Test Files | Test Files]]
Line 14: Line 14:     
== Data structures ==
 
== Data structures ==
# Data Dictionary ([http://java.sun.com/j2se/1.6.0/docs/api/java/util/TreeMap.html TreeMap] and [http://java.sun.com/j2se/1.6.0/docs/api/java/util/TreeSet.html TreeSet] for part 1)
+
#Data Dictionary ([http://java.sun.com/j2se/1.6.0/docs/api/java/util/TreeMap.html TreeMap] and [http://java.sun.com/j2se/1.6.0/docs/api/java/util/TreeSet.html TreeSet] for part 1)
#* Related commands:
+
#*Related commands:
 
#** [[createCity]]
 
#** [[createCity]]
#** [[deleteCity]]
   
#** [[listCities]]
 
#** [[listCities]]
#** [[clearAll]]
  −
# Spatial Map ([[PM Quadtree]] (Updated) for part 1)
  −
#* Related commands:
  −
#** [[mapCity]]
  −
#** [[unmapCity]]
  −
#** [[rangeCities]]
  −
#** [[nearestCity]]
  −
#** [[printPRQuadtree]]
  −
#** [[saveMap]]
   
#** [[clearAll]]
 
#** [[clearAll]]
    
== Commands ==
 
== Commands ==
The operations you will need to support can be gleaned from the [http://www.cs.umd.edu/users/meesh/420/part1/p11/node21.html input specification]:
+
The operations you will need to support can be gleaned from the spec:
   −
* [[createCity]] and [[deleteCity]]: You will need to be able to register cities with and remove them from the data dictionary. No two cities can have the same coordinates or name.
+
* [[createCity]]: You will need to be able to register cities with the data dictionary. No two cities can have the same coordinates or name.
 
* [[clearAll]]: Clears all of the data structures, removing all elements.
 
* [[clearAll]]: Clears all of the data structures, removing all elements.
 
* [[listCities]]: Output a sorted (XML) list of cities in the data dictionary.
 
* [[listCities]]: Output a sorted (XML) list of cities in the data dictionary.
* [[mapCity]] and [[unmapCity]]: Insert a named city into or remove a named city from the spatial map.
  −
* [[printPRQuadtree]]: This outputs an XML (textual) representation of the spatial map.
  −
* [[saveMap]]: This outputs a visual representation (an image) of the spatial data structure.  See [http://wam.umd.edu/~bzoller/cmsc420/doc/cmsc420/drawing/CanvasPlus.html CanvasPlus].
  −
* [[rangeCities]]: This searches the spatial data structure for all cities within a given radius of a given point.
  −
* [[nearestCity]]: This finds the nearest city to a given point in the spatial map.
      
== Output ==
 
== Output ==
   −
The conventions in the spec can be found [http://www.cs.umd.edu/users/meesh/420/part1/p11/node21.html here]
+
The general conventions in the spec can be found [https://www.cs.umd.edu/users/meesh/420/ProjectBook/part1/p11/node20.html here] and the more specific directions for each commands can be found [https://www.cs.umd.edu/users/meesh/420/ProjectBook/part1/p11/node22.html here]
* <[[success]]>: This is when your parser has sucessfully parsed and finished a command.
+
* '''<success>''': This is when your parser has successfully parsed and finished a command.
* <[[error]]>: When an error occurs after attempting to run a command
+
* '''<error>''': When an error occurs after attempting to run a command
* <[[fatalError]]>: There is a problem with the entire document
+
* '''<fatalError>''': There is a problem with the entire document
* <[[undefinedError]]>: Defalut error, when we aren't sure exactly what happened
+
* '''<undefinedError>''': Default error, when we aren't sure exactly what happened
* <[[city]]>: The spec says it should be sorted and in the <output> tag but I am not sure how this works... explain if you do please
+
 
 +
By the end, your output will be XML that minimally looks like this:
 +
 
 +
<results>
 +
    <success ... />
 +
    <success ... />
 +
    <success ... />
 +
    <error ... />
 +
    <success ... />
 +
    ...
 +
    <success ... />
 +
</results>
    
== Testing ==
 
== Testing ==
editor
32

edits