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 LayerGraphicWarehouseSupport

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

All Implemented Interfaces:
  VPFGraphicWarehouse, VPFWarehouse

Direct Known Subclasses:
  VPFLayerDCWWarehouse, VPFLayerGraphicWarehouse

public abstract class LayerGraphicWarehouseSupport
extends java.lang.Object
implements VPFGraphicWarehouse

Implement a graphic factory that builds OMGraphics.

See Also:
  `OMGraphic`

Field Summary
`protected static float` | `antarcticaThreshold` HACK around antarctica display problem.
`protected OMGraphicList` | `areaSubList`
`protected DrawingAttributes` | `drawingAttributes`
`protected OMGraphicList` | `edgeSubList`
`protected OMGraphicList` | `graphics` hang on to the graphics that we build
`protected OMGraphicList` | `pointSubList`
`protected OMGraphicList` | `textSubList`

Constructor Summary
`LayerGraphicWarehouseSupport()` Construct an object, initialiazes graphiclist

Method Summary
`protected void` | `addArea(OMGraphic area)`
`protected void` | `addEdge(OMGraphic edge)`
`protected void` | `addPoint(OMGraphic point)`
`protected void` | `addText(OMGraphic text)`
`void` | `clear()` Clears the contained list of graphics.
`static OMPoly` | `createAreaOMPoly(java.util.List ipts, int totalSize, LatLonPoint ll1, LatLonPoint ll2, float dpplat, float dpplon, boolean doAntarcticaWorkaround)` create a filled polygon
`static OMPoly` | `createEdgeOMPoly(CoordFloatString coords, LatLonPoint ll1, LatLonPoint ll2, float dpplat, float dpplon)` Create an OMPoly corresponding to a VPF edge feature
`static OMPoint` | `createOMPoint(float latitude, float longitude)` Create an OMPoint object corresponding to a VPF node feature
`static OMText` | `createOMText(java.lang.String text, float latitude, float longitude)` Create an OMText object corresponding to a VPF text feature
`protected static int` | `doThinning(java.util.List ipts)` do fan compression of raw edge points
`boolean` | `drawAreaFeatures()` Return true if we may draw some area features.
`boolean` | `drawCPointFeatures()` Return true if we may draw some connected point features.
`boolean` | `drawEdgeFeatures()` Return true if we may draw some edge features.
`boolean` | `drawEPointFeatures()` Return true if we may draw some entity point features.
`boolean` | `drawTextFeatures()` Return true if we may draw some text features.
`DrawingAttributes` | `getDrawingAttributes()` Get the DrawingAttributes used for the coverage type.
`static double` | `getFanEpsilon()` Get fan compression epsilon.
`java.lang.String` | `getFeatureString()`
`OMGraphicList` | `getGraphics()` Get the current graphics list.
`protected OMGraphicList` | `getGraphics(OMGraphicList addToList)` Add the area, edge, text and point sublists to the provided list.
`java.awt.Component` | `getGUI(LibrarySelectionTable lst)` Return the GUI for certain warehouse attributes.
`java.util.Properties` | `getProperties(java.util.Properties props)` set drawing attribute properties
`java.lang.String` | `getUseLibrary()` Get the VPF library to use.
`protected void` | `initDrawingAttributes()` Called from super class constructor.
`static boolean` | `isDoThinning()` Are we thinning?.
`void` | `resetForCAT()` Lets the warehouse know that a different CoverageAttributeTable will be using it.
`void` | `setAreaFeatures(boolean newvalue)` set if we draw area features
`void` | `setCPointFeatures(boolean newvalue)` set if we draw connected point features
`static void` | `setDoThinning(boolean value)` Set doThinning.
`void` | `setDrawingAttributes(DrawingAttributes da)` Set the drawing attributes for the coverage type.
`void` | `setEdgeFeatures(boolean newvalue)` set if we draw edge features
`void` | `setEPointFeatures(boolean newvalue)` set if we draw entity point features
`static void` | `setFanEpsilon(double value)` Set fan compression epsilon.
`void` | `setFeatures(java.lang.String features)` Sets the features (lines, areas, text, points) that get displayed
`void` | `setProperties(java.lang.String prefix, java.util.Properties props)` set drawing attribute properties
`void` | `setTextFeatures(boolean newvalue)` set if we draw text features
`void` | `setUseLibrary(java.lang.String lib)` Set the VPF library to use.

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.VPFGraphicWarehouse
`createArea, createEdge, createNode, createText`

Methods inherited from interface com.bbn.openmap.layer.vpf.VPFWarehouse
`getFeatures`

Field Detail

### drawingAttributes

    protected DrawingAttributes drawingAttributes

### antarcticaThreshold

    protected static final transient float antarcticaThreshold

  HACK around antarctica display problem.

### graphics

    protected OMGraphicList graphics

  hang on to the graphics that we build

### areaSubList

    protected OMGraphicList areaSubList

### edgeSubList

    protected OMGraphicList edgeSubList

### textSubList

    protected OMGraphicList textSubList

### pointSubList

    protected OMGraphicList pointSubList

Constructor Detail

### LayerGraphicWarehouseSupport

    public LayerGraphicWarehouseSupport()

  Construct an object, initialiazes graphiclist

Method Detail

### initDrawingAttributes

    protected void initDrawingAttributes()

  Called from super class constructor.

### getGraphics

    public OMGraphicList getGraphics()

  Get the current graphics list.

  Returns:
    the OMGraphicList.

### getGraphics

    protected OMGraphicList getGraphics(OMGraphicList addToList)

  Add the area, edge, text and point sublists to the provided list.

### getDrawingAttributes

    public DrawingAttributes getDrawingAttributes()

  Get the DrawingAttributes used for the coverage type.

### setDrawingAttributes

    public void setDrawingAttributes(DrawingAttributes da)

  Set the drawing attributes for the coverage type.

### resetForCAT

    public void resetForCAT()

  Lets the warehouse know that a different CoverageAttributeTable will be using it. Default action is to do nothing.

  Specified by:
    `resetForCAT` in interface `VPFWarehouse`

### setUseLibrary

    public void setUseLibrary(java.lang.String lib)

  Set the VPF library to use. If null, all libraries will be searched. Null is default.

  Specified by:
    `setUseLibrary` in interface `VPFWarehouse`

### getUseLibrary

    public java.lang.String getUseLibrary()

  Get the VPF library to use.

  Specified by:
    `getUseLibrary` in interface `VPFWarehouse`

### 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`
  Parameters:
    `lst` - LibrarySelectionTable to use to get information about the data, if needed. Not needed here.

### clear

    public void clear()

  Clears the contained list of graphics.

### addArea

    protected void addArea(OMGraphic area)

### addEdge

    protected void addEdge(OMGraphic edge)

### addText

    protected void addText(OMGraphic text)

### addPoint

    protected void addPoint(OMGraphic point)

### setEdgeFeatures

    public void setEdgeFeatures(boolean newvalue)

  set if we draw edge features

  Parameters:
    `newvalue` - `true` for drawing, false otherwise

### drawEdgeFeatures

    public boolean drawEdgeFeatures()

  Return true if we may draw some edge features.

  Specified by:
    `drawEdgeFeatures` in interface `VPFWarehouse`

### setTextFeatures

    public void setTextFeatures(boolean newvalue)

  set if we draw text features

  Parameters:
    `newvalue` - `true` for drawing, false otherwise

### drawTextFeatures

    public boolean drawTextFeatures()

  Return true if we may draw some text features.

  Specified by:
    `drawTextFeatures` in interface `VPFWarehouse`

### setAreaFeatures

    public void setAreaFeatures(boolean newvalue)

  set if we draw area features

  Parameters:
    `newvalue` - `true` for drawing, false otherwise

### drawAreaFeatures

    public boolean drawAreaFeatures()

  Return true if we may draw some area features.

  Specified by:
    `drawAreaFeatures` in interface `VPFWarehouse`

### setEPointFeatures

    public void setEPointFeatures(boolean newvalue)

  set if we draw entity point features

  Parameters:
    `newvalue` - `true` for drawing, false otherwise

### drawEPointFeatures

    public boolean drawEPointFeatures()

  Return true if we may draw some entity point features.

  Specified by:
    `drawEPointFeatures` in interface `VPFWarehouse`

### setCPointFeatures

    public void setCPointFeatures(boolean newvalue)

  set if we draw connected point features

  Parameters:
    `newvalue` - `true` for drawing, false otherwise

### drawCPointFeatures

    public boolean drawCPointFeatures()

  Return true if we may draw some connected point features.

  Specified by:
    `drawCPointFeatures` in interface `VPFWarehouse`

### setFeatures

    public void setFeatures(java.lang.String features)

  Sets the features (lines, areas, text, points) that get displayed

  Parameters:
    `features` - a whitespace-separated list of features to display

### getFeatureString

    public java.lang.String getFeatureString()

### setProperties

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

  set drawing attribute properties

  Parameters:
    `prefix` - the prefix for our properties
    `props` - the Properties object we use to look up valuse

### getProperties

    public java.util.Properties getProperties(java.util.Properties props)

  set drawing attribute properties

  Parameters:
    `props` - the Properties object.

### createAreaOMPoly

    public static OMPoly createAreaOMPoly(java.util.List ipts,
                                          int totalSize,
                                          LatLonPoint ll1,
                                          LatLonPoint ll2,
                                          float dpplat,
                                          float dpplon,
                                          boolean doAntarcticaWorkaround)

  create a filled polygon

  Parameters:
    `ipts` - a list of CoordFloatString objects
    `totalSize` - the total number of points
    `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)
    `doAntarcticaWorkaround` - hack for funny DCW antarctica data (passed to warehouse)

### createEdgeOMPoly

    public static OMPoly createEdgeOMPoly(CoordFloatString coords,
                                          LatLonPoint ll1,
                                          LatLonPoint ll2,
                                          float dpplat,
                                          float dpplon)

  Create an OMPoly corresponding to a VPF edge feature

  Parameters:
    `coords` - the coordinates to use for the poly
    `ll1` - upper left, used for clipping
    `ll2` - lower right, used for clipping
    `dpplat` - used for latitude thinning
    `dpplon` - used for longitude thinning

### setDoThinning

    public static void setDoThinning(boolean value)

  Set doThinning.

  Parameters:
    `value` - boolean

### isDoThinning

    public static boolean isDoThinning()

  Are we thinning?.

  Returns:
    boolean

### setFanEpsilon

    public static void setFanEpsilon(double value)

  Set fan compression epsilon.

  Parameters:
    `value` - double

### getFanEpsilon

    public static double getFanEpsilon()

  Get fan compression epsilon.

  Returns:
    double

### doThinning

    protected static int doThinning(java.util.List ipts)

  do fan compression of raw edge points

### createOMText

    public static OMText createOMText(java.lang.String text,
                                      float latitude,
                                      float longitude)

  Create an OMText object corresponding to a VPF text feature

  Parameters:
    `text` - the text
    `latitude` - the latitude of where to place the text
    `longitude` - the longitude of where to place the text

### createOMPoint

    public static OMPoint createOMPoint(float latitude,
                                        float longitude)

  Create an OMPoint object corresponding to a VPF node feature

  Parameters:
    `latitude` - the latitude of where to place the text
    `longitude` - the longitude of where to place the text

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