| Constructor and Description |
|---|
LegacyMap()
Construct an empty map.
|
LegacyMap(java.io.File baseDir)
Construct a map and read from a directory.
|
| Modifier and Type | Method and Description |
|---|---|
LegacyBuilding |
getBuilding(int id)
Get a building by ID.
|
java.util.Collection<LegacyBuilding> |
getBuildings()
Get all buildings.
|
LegacyNode |
getNode(int id)
Get a node by ID.
|
java.util.Collection<LegacyNode> |
getNodes()
Get all nodes.
|
LegacyRoad |
getRoad(int id)
Get a road by ID.
|
java.util.Collection<LegacyRoad> |
getRoads()
Get all roads.
|
void |
read(java.io.File baseDir)
Read map data from a directory.
|
public LegacyMap()
public LegacyMap(java.io.File baseDir)
throws java.io.IOException
baseDir - The map directory.java.io.IOException - If there is a problem reading the map.public void read(java.io.File baseDir)
throws java.io.IOException
baseDir - The map directory.java.io.IOException - If there is a problem reading the map.public java.util.Collection<LegacyRoad> getRoads()
public LegacyRoad getRoad(int id)
id - The ID to look up.public java.util.Collection<LegacyNode> getNodes()
public LegacyNode getNode(int id)
id - The ID to look up.public java.util.Collection<LegacyBuilding> getBuildings()
public LegacyBuilding getBuilding(int id)
id - The ID to look up.