com.bbn.openmap.layer.vpf
Class EdgeTable

java.lang.Object
  extended by com.bbn.openmap.layer.vpf.DcwRecordFile
      extended by com.bbn.openmap.layer.vpf.PrimitiveTable
          extended by com.bbn.openmap.layer.vpf.EdgeTable

public class EdgeTable
extends PrimitiveTable

Read VPF format edge tables to generate polyline graphics for OpenMap.


Field Summary
 
Fields inherited from class com.bbn.openmap.layer.vpf.PrimitiveTable
covtable, idColumn, tile
 
Fields inherited from class com.bbn.openmap.layer.vpf.DcwRecordFile
byteorder, columnInfo, documentationFileName, filename, ID_COLUMN_NAME, inputFile, MSBFirst, recordLength, tableDescription, tablename, vli
 
Constructor Summary
EdgeTable(CoverageTable cov, TileDirectory tile)
          Construct an EdgeTable object for a tile of a coverage.
 
Method Summary
 OMGraphic drawFeature(VPFFeatureWarehouse warehouse, double dpplat, double dpplon, LatLonPoint ll1, LatLonPoint ll2, java.util.List<java.lang.Object> edge, java.lang.String featureType, int primID)
          Use the warehouse to create a graphic from the edge feature, if you already have the line from the edgetable.
 void drawTile(VPFGraphicWarehouse warehouse, double dpplat, double dpplon, LatLonPoint ll1, LatLonPoint ll2)
          Parse the edge records for this tile, calling warehouse.createEdge once for each record.
 CoordFloatString getCoordinates(java.util.List<java.lang.Object> l)
          Get the value of the coordinates column
 CoverageTable getCoverageTable()
          get the coverage table that this edge is in
 int getEndNode(java.util.List<java.lang.Object> l)
          Get the value of the end_node column
 int getID(java.util.List<java.lang.Number> l)
          Get the value of the ID column
 TilingAdapter getLeftEdgeTilingAdapter()
          Get the TilingAdapter for the left_edge column
 TilingAdapter getLeftFaceTilingAdapter()
          Get the TilingAdapter for the left_face column
 TilingAdapter getRightEdgeTilingAdapter()
          Get the TilingAdapter for the right_edge column
 TilingAdapter getRightFaceTilingAdapter()
          Get the TilingAdapter for the right_face column
 int getStartNode(java.util.List<java.lang.Object> l)
          Get the value of the start_node column
 int topologyLevel()
          get the topology level of the edge table
 
Methods inherited from class com.bbn.openmap.layer.vpf.PrimitiveTable
getTileDirectory
 
Methods inherited from class com.bbn.openmap.layer.vpf.DcwRecordFile
close, finalize, finishInitialization, getColumnCount, getColumnInfo, getColumnName, getDescription, getDocumentationFilename, getRecordCount, getRecordLength, getRow, getRow, getTableFile, getTableName, getTilingAdapter, getTilingAdapter, getTilingAdapter, lookupSchema, lookupSchema, main, parseAllRowsAndPrintSome, parseRow, parseRow, parseSomeRowsAndPrint, printSchema, reopen, seekToRow, whatColumn
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EdgeTable

public EdgeTable(CoverageTable cov,
                 TileDirectory tile)
          throws FormatException
Construct an EdgeTable object for a tile of a coverage.

Parameters:
cov - the coverage table that this tile is part of
tile - the tile to parse
Throws:
FormatException - a problem was encountered initializing this tile
Method Detail

getID

public final int getID(java.util.List<java.lang.Number> l)
Get the value of the ID column

Overrides:
getID in class PrimitiveTable
Parameters:
l - the list to retrieve the value from

getStartNode

public final int getStartNode(java.util.List<java.lang.Object> l)
Get the value of the start_node column

Parameters:
l - the list to retrieve the value from

getEndNode

public final int getEndNode(java.util.List<java.lang.Object> l)
Get the value of the end_node column

Parameters:
l - the list to retrieve the value from

getRightFaceTilingAdapter

public final TilingAdapter getRightFaceTilingAdapter()
Get the TilingAdapter for the right_face column


getLeftFaceTilingAdapter

public final TilingAdapter getLeftFaceTilingAdapter()
Get the TilingAdapter for the left_face column


getRightEdgeTilingAdapter

public final TilingAdapter getRightEdgeTilingAdapter()
Get the TilingAdapter for the right_edge column


getLeftEdgeTilingAdapter

public final TilingAdapter getLeftEdgeTilingAdapter()
Get the TilingAdapter for the left_edge column


getCoordinates

public final CoordFloatString getCoordinates(java.util.List<java.lang.Object> l)
Get the value of the coordinates column

Parameters:
l - the list to retrieve the value from

topologyLevel

public int topologyLevel()
get the topology level of the edge table

Returns:
the vpf topology level

getCoverageTable

public CoverageTable getCoverageTable()
get the coverage table that this edge is in

Overrides:
getCoverageTable in class PrimitiveTable

drawTile

public void drawTile(VPFGraphicWarehouse warehouse,
                     double dpplat,
                     double dpplon,
                     LatLonPoint ll1,
                     LatLonPoint ll2)
Parse the edge records for this tile, calling warehouse.createEdge once for each record.

Specified by:
drawTile in class PrimitiveTable
Parameters:
warehouse - the warehouse used for createEdge calls (must not be null)
dpplat - threshold for latitude thinning (passed to warehouse)
dpplon - threshold for longitude thinngin (passed to warehouse)
ll1 - upperleft of selection region (passed to warehouse)
ll2 - lowerright of selection region (passed to warehouse)
See Also:
VPFGraphicWarehouse.createEdge(com.bbn.openmap.layer.vpf.CoverageTable, com.bbn.openmap.layer.vpf.EdgeTable, java.util.List, com.bbn.openmap.proj.coords.LatLonPoint, com.bbn.openmap.proj.coords.LatLonPoint, double, double, com.bbn.openmap.layer.vpf.CoordFloatString)

drawFeature

public OMGraphic drawFeature(VPFFeatureWarehouse warehouse,
                             double dpplat,
                             double dpplon,
                             LatLonPoint ll1,
                             LatLonPoint ll2,
                             java.util.List<java.lang.Object> edge,
                             java.lang.String featureType,
                             int primID)
Use the warehouse to create a graphic from the edge feature, if you already have the line from the edgetable.

Specified by:
drawFeature in class PrimitiveTable
Parameters:
warehouse - the warehouse used for createEdge calls (must not be null)
dpplat - threshold for latitude thinning (passed to warehouse)
dpplon - threshold for longitude thinngin (passed to warehouse)
ll1 - upperleft of selection region (passed to warehouse)
ll2 - lowerright of selection region (passed to warehouse)
edge - list containing the EdgeTable row contents.
featureType - the name of the feature. The warehouse may want to do some intelligent rendering.
primID - the primitive ID of the feature, in order to gather attributes if necessary.
See Also:
VPFGraphicWarehouse.createEdge(com.bbn.openmap.layer.vpf.CoverageTable, com.bbn.openmap.layer.vpf.EdgeTable, java.util.List, com.bbn.openmap.proj.coords.LatLonPoint, com.bbn.openmap.proj.coords.LatLonPoint, double, double, com.bbn.openmap.layer.vpf.CoordFloatString)


Copyright (C) BBNT Solutions LLC; See http://openmap.bbn.com/ for details