|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.bbn.openmap.layer.vpf.LayerGraphicWarehouseSupport com.bbn.openmap.layer.vpf.VPFLayerGraphicWarehouse com.bbn.openmap.layer.vpf.VPFFeatureGraphicWarehouse
public class VPFFeatureGraphicWarehouse
Implement a graphic factory that builds OMGraphics. It's different in that it expects that the feature type has already been checked at the CoverageTable level, and should just build whatever graphic is sent to it. Called from within CoverageTable.drawFeatures().
OMGraphic
Field Summary | |
---|---|
static java.lang.String |
DEFAULT
|
protected java.util.Hashtable<java.lang.String,DrawingAttributes> |
featureDrawingAttributes
|
protected java.lang.String |
info
|
Fields inherited from class com.bbn.openmap.layer.vpf.LayerGraphicWarehouseSupport |
---|
antarcticaThreshold, areaSubList, drawingAttributes, edgeSubList, graphics, logger, pointSubList, textSubList |
Constructor Summary | |
---|---|
VPFFeatureGraphicWarehouse()
|
Method Summary | |
---|---|
OMGraphic |
createArea(CoverageTable covtable,
AreaTable areatable,
java.util.List<java.lang.Object> facevec,
LatLonPoint ll1,
LatLonPoint ll2,
double dpplat,
double dpplon,
java.lang.String featureType,
int primID)
|
OMGraphic |
createEdge(CoverageTable c,
EdgeTable edgetable,
java.util.List<java.lang.Object> edgevec,
LatLonPoint ll1,
LatLonPoint ll2,
double dpplat,
double dpplon,
CoordFloatString coords,
java.lang.String featureType,
int primID)
|
void |
createFeatureDrawingAttributes(java.lang.String prefix,
java.util.Properties props,
java.util.List<java.lang.String> features)
From the initial properties, create the hashtable that holds the DrawingAttributes object for each feature type. |
OMGraphic |
createNode(CoverageTable c,
NodeTable t,
java.util.List<java.lang.Object> nodeprim,
double latitude,
double longitude,
boolean isEntityNode,
java.lang.String featureType,
int primID)
Method called by the VPF reader code to construct a node feature. |
OMGraphic |
createText(CoverageTable c,
TextTable texttable,
java.util.List<java.lang.Object> textvec,
double latitude,
double longitude,
java.lang.String text,
java.lang.String featureType,
int primID)
|
FeatureDrawingAttributes |
getAttributesForFeature(java.lang.String featureType)
Given a feature type, get the DrawingAttributes for that feature. |
java.util.Hashtable<java.lang.String,DrawingAttributes> |
getFeatureDrawingAttributes()
Get the Hashtable used for the feature DrawingAttributes lookup. |
java.awt.Component |
getGUI(LibrarySelectionTable lst)
Return the GUI for certain warehouse attributes. |
protected void |
initDrawingAttributes()
Called from super class constructor. |
static void |
main(java.lang.String[] argv)
|
boolean |
needToFetchTileContents(java.lang.String libraryName,
java.lang.String currentFeature,
TileDirectory currentTile)
|
protected void |
setAttributesForFeature(OMGraphic omg,
CoverageTable c,
java.lang.String featureType,
int id)
|
void |
setFeatureDrawingAttributes(java.util.Hashtable<java.lang.String,DrawingAttributes> attributes)
Don't do this lightly, or everything will be colored the default value. |
void |
setProperties(java.lang.String prefix,
java.util.Properties props)
Set properties of the warehouse. |
Methods inherited from class com.bbn.openmap.layer.vpf.VPFLayerGraphicWarehouse |
---|
createArea, createEdge, createFeature, createNode, createText, getFeatures, getSkipArray, resetForCAT |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.bbn.openmap.layer.vpf.VPFWarehouse |
---|
checkLibraryForUsage, drawAreaFeatures, drawCPointFeatures, drawEdgeFeatures, drawEPointFeatures, drawTextFeatures, getFeatures, getUseLibraries, resetForCAT, setUseLibraries |
Field Detail |
---|
public static final java.lang.String DEFAULT
protected java.util.Hashtable<java.lang.String,DrawingAttributes> featureDrawingAttributes
protected java.lang.String info
Constructor Detail |
---|
public VPFFeatureGraphicWarehouse()
Method Detail |
---|
protected void initDrawingAttributes()
initDrawingAttributes
in class LayerGraphicWarehouseSupport
public void setProperties(java.lang.String prefix, java.util.Properties props)
setProperties
in class VPFLayerGraphicWarehouse
prefix
- the prefix to use for looking up properties.props
- the properties file to look at.public void createFeatureDrawingAttributes(java.lang.String prefix, java.util.Properties props, java.util.List<java.lang.String> features)
prefix
- the prefix used for the propertiesprops
- the properties objectfeatures
- a List of Strings, each representing a feature type that
when appended to the prefix, will serve as a prefix for the
drawing attributes settings for that feature. With a layer prefix
of vmapRoads, and a feature type of roadl, the line color
attribute property looked for will be vmapRoads.roadl.lineColor.public void setFeatureDrawingAttributes(java.util.Hashtable<java.lang.String,DrawingAttributes> attributes)
public java.util.Hashtable<java.lang.String,DrawingAttributes> getFeatureDrawingAttributes()
public java.awt.Component getGUI(LibrarySelectionTable lst)
getGUI
in interface VPFWarehouse
getGUI
in class LayerGraphicWarehouseSupport
lst
- LibrarySelectionTable to use to get information about the
data, if needed.public FeatureDrawingAttributes getAttributesForFeature(java.lang.String featureType)
public OMGraphic createArea(CoverageTable covtable, AreaTable areatable, java.util.List<java.lang.Object> facevec, LatLonPoint ll1, LatLonPoint ll2, double dpplat, double dpplon, java.lang.String featureType, int primID)
createArea
in interface VPFFeatureWarehouse
public OMGraphic createEdge(CoverageTable c, EdgeTable edgetable, java.util.List<java.lang.Object> edgevec, LatLonPoint ll1, LatLonPoint ll2, double dpplat, double dpplon, CoordFloatString coords, java.lang.String featureType, int primID)
createEdge
in interface VPFFeatureWarehouse
protected void setAttributesForFeature(OMGraphic omg, CoverageTable c, java.lang.String featureType, int id)
omg
- The OMGraphic owning the attributes.c
- the CoverageTable for the feature.featureType
- the type of Feature.id
- ID of the OMGraphic.public OMGraphic createText(CoverageTable c, TextTable texttable, java.util.List<java.lang.Object> textvec, double latitude, double longitude, java.lang.String text, java.lang.String featureType, int primID)
createText
in interface VPFFeatureWarehouse
public OMGraphic createNode(CoverageTable c, NodeTable t, java.util.List<java.lang.Object> nodeprim, double latitude, double longitude, boolean isEntityNode, java.lang.String featureType, int primID)
createNode
in interface VPFFeatureWarehouse
public boolean needToFetchTileContents(java.lang.String libraryName, java.lang.String currentFeature, TileDirectory currentTile)
needToFetchTileContents
in interface VPFFeatureWarehouse
public static void main(java.lang.String[] argv)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |