Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bbn.openmap.layer.vpf
Class VPFFeatureGraphicWarehouse

    java.lang.Object
      com.bbn.openmap.layer.vpf.LayerGraphicWarehouseSupport
          com.bbn.openmap.layer.vpf.VPFLayerGraphicWarehouse
              com.bbn.openmap.layer.vpf.VPFFeatureGraphicWarehouse

All Implemented Interfaces:
  VPFFeatureWarehouse, VPFGraphicWarehouse, VPFWarehouse

Direct Known Subclasses:
  VPFCachedFeatureGraphicWarehouse

public class VPFFeatureGraphicWarehouse
extends VPFLayerGraphicWarehouse
implements VPFFeatureWarehouse

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().

See Also:
  `OMGraphic`

Field Summary
`static java.lang.String` | `DEFAULT`
`protected java.util.Hashtable` | `featureDrawingAttributes`
`protected java.lang.String` | `info`

Fields inherited from class com.bbn.openmap.layer.vpf.LayerGraphicWarehouseSupport
`antarcticaThreshold, areaSubList, drawingAttributes, edgeSubList, graphics, pointSubList, textSubList`

Constructor Summary
`VPFFeatureGraphicWarehouse()`

Method Summary
`void` | `createArea(CoverageTable covtable, AreaTable areatable, java.util.List facevec, LatLonPoint ll1, LatLonPoint ll2, float dpplat, float dpplon, java.lang.String featureType)`
`void` | `createEdge(CoverageTable c, EdgeTable edgetable, java.util.List edgevec, LatLonPoint ll1, LatLonPoint ll2, float dpplat, float dpplon, CoordFloatString coords, java.lang.String featureType)`
`void` | `createFeatureDrawingAttributes(java.lang.String prefix, java.util.Properties props, java.util.List features)` From the initial properties, create the hashtable that holds the DrawingAttributes object for each feature type.
`void` | `createNode(CoverageTable c, NodeTable t, java.util.List nodeprim, float latitude, float longitude, boolean isEntityNode, java.lang.String featureType)` Method called by the VPF reader code to construct a node feature.
`void` | `createText(CoverageTable c, TextTable texttable, java.util.List textvec, float latitude, float longitude, java.lang.String text, java.lang.String featureType)`
`FeatureDrawingAttributes` | `getAttributesForFeature(java.lang.String featureType)` Given a feature type, get the DrawingAttributes for that feature.
`java.util.Hashtable` | `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 currentFeature, TileDirectory currentTile)`
`protected void` | `setAttributesForFeature(OMGraphic omg, CoverageTable c, java.lang.String featureType, int id)`
`void` | `setFeatureDrawingAttributes(java.util.Hashtable 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 com.bbn.openmap.layer.vpf.LayerGraphicWarehouseSupport
`addArea, addEdge, addPoint, addText, clear, createAreaOMPoly, createEdgeOMPoly, createOMPoint, createOMText, doThinning, drawAreaFeatures, drawCPointFeatures, drawEdgeFeatures, drawEPointFeatures, drawTextFeatures, getDrawingAttributes, getFanEpsilon, getFeatureString, getGraphics, getGraphics, getProperties, getUseLibrary, isDoThinning, setAreaFeatures, setCPointFeatures, setDoThinning, setDrawingAttributes, setEdgeFeatures, setEPointFeatures, setFanEpsilon, setFeatures, setTextFeatures, setUseLibrary`

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
`drawAreaFeatures, drawCPointFeatures, drawEdgeFeatures, drawEPointFeatures, drawTextFeatures, getFeatures, getUseLibrary, resetForCAT, setUseLibrary`

Field Detail

### DEFAULT

    public static final java.lang.String DEFAULT

See Also:
  Constant Field Values

### featureDrawingAttributes

    protected java.util.Hashtable featureDrawingAttributes

### info

    protected java.lang.String info

Constructor Detail

### VPFFeatureGraphicWarehouse

    public VPFFeatureGraphicWarehouse()

Method Detail

### initDrawingAttributes

    protected void initDrawingAttributes()

  Called from super class constructor.

  Overrides:
    `initDrawingAttributes` in class `LayerGraphicWarehouseSupport`

### setProperties

    public void setProperties(java.lang.String prefix,
                              java.util.Properties props)

  Set properties of the warehouse.

  Overrides:
    `setProperties` in class `VPFLayerGraphicWarehouse`
  Parameters:
    `prefix` - the prefix to use for looking up properties.
    `props` - the properties file to look at.

### createFeatureDrawingAttributes

    public void createFeatureDrawingAttributes(java.lang.String prefix,
                                               java.util.Properties props,
                                               java.util.List features)

  From the initial properties, create the hashtable that holds the DrawingAttributes object for each feature type. The feature name is the key to the drawing attributes for that feature (roadl).

  Parameters:
    `prefix` - the prefix used for the properties
    `props` - the properties object
    `features` - 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.

### setFeatureDrawingAttributes

    public void setFeatureDrawingAttributes(java.util.Hashtable attributes)

  Don't do this lightly, or everything will be colored the default value. The keys to the Hashtable should be the feature type names, and the values should be the DrawingAttributes for that feature.

### getFeatureDrawingAttributes

    public java.util.Hashtable getFeatureDrawingAttributes()

  Get the Hashtable used for the feature DrawingAttributes lookup.

### getGUI

    public java.awt.Component getGUI(LibrarySelectionTable lst)

  Return the GUI for certain warehouse attributes. By default, return the GUI for the DrawingAttributes object being used for rendering attributes of the graphics.

  Specified by:
    `getGUI` in interface `VPFWarehouse`
  Overrides:
    `getGUI` in class `LayerGraphicWarehouseSupport`
  Parameters:
    `lst` - LibrarySelectionTable to use to get information about the data, if needed.

### getAttributesForFeature

    public FeatureDrawingAttributes getAttributesForFeature(java.lang.String featureType)

  Given a feature type, get the DrawingAttributes for that feature. Should be very unlikely to get a null value back.

### createArea

    public void createArea(CoverageTable covtable,
                           AreaTable areatable,
                           java.util.List facevec,
                           LatLonPoint ll1,
                           LatLonPoint ll2,
                           float dpplat,
                           float dpplon,
                           java.lang.String featureType)

  Specified by:
    `createArea` in interface `VPFFeatureWarehouse`

### createEdge

    public void createEdge(CoverageTable c,
                           EdgeTable edgetable,
                           java.util.List edgevec,
                           LatLonPoint ll1,
                           LatLonPoint ll2,
                           float dpplat,
                           float dpplon,
                           CoordFloatString coords,
                           java.lang.String featureType)

  Specified by:
    `createEdge` in interface `VPFFeatureWarehouse`

### setAttributesForFeature

    protected void setAttributesForFeature(OMGraphic omg,
                                           CoverageTable c,
                                           java.lang.String featureType,
                                           int id)

  Parameters:
    `omg` - The OMGraphic owning the attributes.
    `c` - the CoverageTable for the feature.
    `featureType` - the type of Feature.
    `id` - ID of the OMGraphic.

### createText

    public void createText(CoverageTable c,
                           TextTable texttable,
                           java.util.List textvec,
                           float latitude,
                           float longitude,
                           java.lang.String text,
                           java.lang.String featureType)

  Specified by:
    `createText` in interface `VPFFeatureWarehouse`

### createNode

    public void createNode(CoverageTable c,
                           NodeTable t,
                           java.util.List nodeprim,
                           float latitude,
                           float longitude,
                           boolean isEntityNode,
                           java.lang.String featureType)

  Method called by the VPF reader code to construct a node feature.

  Specified by:
    `createNode` in interface `VPFFeatureWarehouse`

### needToFetchTileContents

    public boolean needToFetchTileContents(java.lang.String currentFeature,
                                           TileDirectory currentTile)

  Specified by:
    `needToFetchTileContents` in interface `VPFFeatureWarehouse`

### main

    public static void main(java.lang.String[] argv)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

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