|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectuk.me.parabola.mkgmap.reader.MapperBasedMapDataSource
uk.me.parabola.mkgmap.reader.overview.OverviewMapDataSource
public class OverviewMapDataSource
Class for creating an overview map. Nothing is actually read in from a file, we just save some detail from the other img files that are going into the map set.
Field Summary |
---|
Fields inherited from class uk.me.parabola.mkgmap.reader.MapperBasedMapDataSource |
---|
mapper |
Constructor Summary | |
---|---|
OverviewMapDataSource()
|
Method Summary | |
---|---|
void |
addCopyright(java.lang.String cw)
Add a copyright string to the map. |
void |
addLine(MapLine line)
Add a line to the map. |
void |
addPoint(MapPoint point)
Add a point to the map. |
void |
addRestriction(CoordNode fromNode,
CoordNode toNode,
CoordNode viaNode,
byte exceptMask)
Add a routing restriction to the map. |
void |
addRoad(MapRoad road)
For adding a road. |
void |
addShape(MapShape shape)
Add the given shape (polygon) to the map. |
void |
addThroughRoute(long junctionNodeId,
long roadIdA,
long roadIdB)
Add a through route to the map. |
void |
addToBounds(Coord p)
Add the given point to the total bounds for the map. |
java.lang.String[] |
copyrightMessages()
All the copyright messages that were found in the input files are returned here. |
int |
getShift()
Get the 'shift' value of the overview map. |
boolean |
isFileSupported(java.lang.String name)
This is a fake source of data and is not read from a file, so always return false here. |
void |
load(java.lang.String name)
Load map by name. |
LevelInfo[] |
mapLevels()
Get the map levels for this map. |
Methods inherited from class uk.me.parabola.mkgmap.reader.MapperBasedMapDataSource |
---|
addBackground, addBackground, addBoundaryLine, config, getBounds, getConfig, getLines, getMapper, getOverviews, getPoints, getRoadNetwork, getShapes |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface uk.me.parabola.mkgmap.general.MapDataSource |
---|
getBounds, getLines, getOverviews, getPoints, getRoadNetwork, getShapes |
Methods inherited from interface uk.me.parabola.util.Configurable |
---|
config |
Constructor Detail |
---|
public OverviewMapDataSource()
Method Detail |
---|
public boolean isFileSupported(java.lang.String name)
isFileSupported
in interface LoadableMapDataSource
name
- The filename, ignored.
public void load(java.lang.String name) throws java.io.FileNotFoundException, FormatException
LoadableMapDataSource
load
in interface LoadableMapDataSource
name
- The name of the resource to be loaded.
java.io.FileNotFoundException
- When the file or resource is not found.
FormatException
- For any kind of malformed input.public LevelInfo[] mapLevels()
LoadableMapDataSource
Note that it does not include the top empty level as we will always generate that in the main program automatically.
mapLevels
in interface LoadableMapDataSource
public void addCopyright(java.lang.String cw)
addCopyright
in interface OverviewMap
cw
- The string to add.public java.lang.String[] copyrightMessages()
copyrightMessages
in interface LoadableMapDataSource
public void addToBounds(Coord p)
addToBounds
in interface MapCollector
p
- The coordinates of the point to add. The type here will change to
Node.public void addPoint(MapPoint point)
addPoint
in interface MapCollector
point
- The point to add.public void addLine(MapLine line)
addLine
in interface MapCollector
line
- The line information.public void addShape(MapShape shape)
addShape
in interface MapCollector
shape
- The polygon to add.public void addRoad(MapRoad road)
MapCollector
addRoad
in interface MapCollector
public void addRestriction(CoordNode fromNode, CoordNode toNode, CoordNode viaNode, byte exceptMask)
MapCollector
addRestriction
in interface MapCollector
exceptMask
- For exceptions eg. no-left-turn except for buses.public void addThroughRoute(long junctionNodeId, long roadIdA, long roadIdB)
MapCollector
addThroughRoute
in interface MapCollector
public int getShift()
OverviewMap
getShift
in interface OverviewMap
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |