LocationHandler (OpenMap API)
Date: 2016-12-09

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.location
Interface LocationHandler

All Superinterfaces:
  PropertyConsumer

All Known Implementing Classes:
  AbstractLocationHandler, BasicLocationHandler, CSVLinkHandler, CSVLocationHandler, DBLocationHandler

    public interface LocationHandler

extends PropertyConsumer

The LocationHandler is the LocationLayer interface to the data. It is the bearer of knowledge about how the location data is stored, and has the smarts on creating the locations and links to represent the data on the map. It also provides controls for changing the display of the data, provided through the getGUI() method, and therefore controls how the data is displayed at a supervisory level. Each location handler should have its own set of properties:

         # Properties for LocationHandler
         # Show the graphics for all the locations.
         handler.showLocations=true
         # Show the labels for all the locations.
         handler.showNames=true

Field Summary
`static java.lang.String` | `defaultLocationColorString` The default line color for locations.
`static java.lang.String` | `defaultNameColorString` The default line color for names.
`static java.lang.String` | `forceGlobalCommand` (forceGlobal)
`static java.lang.String` | `ForceGlobalProperty`
`static java.lang.String` | `LocationPropertyPrefix` Property prefix to use to scope properties to be used for location markers, including rendering properties.
`static java.lang.String` | `NamePropertyPrefix` Property prefix to use to scope properties to be used for name markers, including rendering properties.
`static java.lang.String` | `readDataCommand` (readData)
`static java.lang.String` | `showdetails` A default button name used to trigger more information about a location to come up in a web browser.
`static java.lang.String` | `showLocationsCommand` (showLocations)
`static java.lang.String` | `ShowLocationsProperty` Property setting to show location splots on startup.
`static java.lang.String` | `showname` A button name used to turn a location label on/off.
`static java.lang.String` | `showNamesCommand` (showNames)
`static java.lang.String` | `ShowNamesProperty` Property setting to show name data on startup.

Fields inherited from interface com.bbn.openmap.PropertyConsumer
`EditorProperty, initPropertiesProperty, LabelEditorProperty, ScopedEditorProperty`

Method Summary
`OMGraphicList` | `get(double nwLat, double nwLon, double seLat, double seLon, OMGraphicList graphicList)` Fill a vector of OMGraphics to represent the data from this handler.
`java.awt.Component` | `getGUI()` A set of controls to manipulate and control the display of data from the handler.
`java.util.List<java.awt.Component>` | `getItemsForPopupMenu(Location loc)` The location layer passes a LocationPopupMenu to the handler when on of its locations has been clicked on.
`LocationLayer` | `getLayer()` Return the layer that the handler is responding to.
`java.lang.String` | `getPrettyName()` Get the GUI pretty name for the data set retrieved by this LocationHandler.
`boolean` | `isForceGlobal()` Find out whether global settings should override local ones.
`boolean` | `isShowLocations()` See if the handler is displaying location graphics at a global level.
`boolean` | `isShowNames()` See if the handler is displaying labels at a global level.
`void` | `reloadData()` A trigger function to tell the handler that new data is available.
`void` | `removed(java.awt.Container cont)` Called by the LocationLayer when the Layer has been removed from the Map.
`void` | `setForceGlobal(boolean set)` Set whether global settings should override local ones.
`void` | `setLayer(LocationLayer layer)` Set the layer the handler is responding to.
`void` | `setPrettyName(java.lang.String prettyName)` Set the name used in the GUI to represent this data set.
`void` | `setShowLocations(boolean set)` Set the handler to show/hide location graphics at a global level.
`void` | `setShowNames(boolean set)` Set the handler to show/hide labels at a global level.

Methods inherited from interface com.bbn.openmap.PropertyConsumer
`getProperties, getPropertyInfo, getPropertyPrefix, setProperties, setProperties, setPropertyPrefix`

Field Detail

### showdetails

    static final java.lang.String showdetails

  A default button name used to trigger more information about a location to come up in a web browser.

  See Also:
    Constant Field Values

### showname

    static final java.lang.String showname

  A button name used to turn a location label on/off.

  See Also:
    Constant Field Values

### ShowNamesProperty

    static final java.lang.String ShowNamesProperty

  Property setting to show name data on startup. (showNames)

  See Also:
    Constant Field Values

### defaultNameColorString

    static final java.lang.String defaultNameColorString

  The default line color for names. (FF339159)

  See Also:
    Constant Field Values

### ForceGlobalProperty

    static final java.lang.String ForceGlobalProperty

See Also:
  Constant Field Values

### ShowLocationsProperty

    static final java.lang.String ShowLocationsProperty

  Property setting to show location splots on startup. (showLocations)

  See Also:
    Constant Field Values

### defaultLocationColorString

    static final java.lang.String defaultLocationColorString

  The default line color for locations. (FFCE4F3F)

  See Also:
    Constant Field Values

### showLocationsCommand

    static final java.lang.String showLocationsCommand

  (showLocations)

  See Also:
    Constant Field Values

### showNamesCommand

    static final java.lang.String showNamesCommand

  (showNames)

  See Also:
    Constant Field Values

### forceGlobalCommand

    static final java.lang.String forceGlobalCommand

  (forceGlobal)

  See Also:
    Constant Field Values

### readDataCommand

    static final java.lang.String readDataCommand

  (readData)

  See Also:
    Constant Field Values

### NamePropertyPrefix

    static final java.lang.String NamePropertyPrefix

  Property prefix to use to scope properties to be used for name markers, including rendering properties. (name)

  See Also:
    Constant Field Values

### LocationPropertyPrefix

    static final java.lang.String LocationPropertyPrefix

  Property prefix to use to scope properties to be used for location markers, including rendering properties. (location)

  See Also:
    Constant Field Values

Method Detail

### get

    OMGraphicList get(double nwLat,
                      double nwLon,
                      double seLat,
                      double seLon,
                      OMGraphicList graphicList)

  Fill a vector of OMGraphics to represent the data from this handler.

  Parameters:
    `nwLat` - NorthWest latitude of area of interest.
    `nwLon` - NorthWest longitude of area of interest.
    `seLat` - SouthEast latitude of area of interest.
    `seLon` - SouthEast longitude of area of interest.
    `graphicList` - Vector to add Locations to. If null, the LocationHandler should create a new Vector to place graphics into.
  Returns:
    Either the OMGraphicList passed in, or the new one that was created if null.

### reloadData

    void reloadData()

  A trigger function to tell the handler that new data is available.

### getItemsForPopupMenu

    java.util.List<java.awt.Component> getItemsForPopupMenu(Location loc)

  The location layer passes a LocationPopupMenu to the handler when on of its locations has been clicked on. This is an opportunity for the handler to add options to the menu that can bring up further information about the location, or to change the appearance of the location.

  Parameters:
    `loc` - Location that items should be provided for.

### getLayer

    LocationLayer getLayer()

  Return the layer that the handler is responding to.

### setLayer

    void setLayer(LocationLayer layer)

  Set the layer the handler is responding to. This is needed in case the handler has updates that it wants to show, and needs to trigger a repaint. It can also be used to communicate with the information delegator.

  Parameters:
    `layer` - a LocationLayer

### isShowNames

    boolean isShowNames()

  See if the handler is displaying labels at a global level.

### setShowNames

    void setShowNames(boolean set)

  Set the handler to show/hide labels at a global level.

### isShowLocations

    boolean isShowLocations()

  See if the handler is displaying location graphics at a global level.

### setShowLocations

    void setShowLocations(boolean set)

  Set the handler to show/hide location graphics at a global level.

### isForceGlobal

    boolean isForceGlobal()

  Find out whether global settings should override local ones.

### setForceGlobal

    void setForceGlobal(boolean set)

  Set whether global settings should override local ones.

### getGUI

    java.awt.Component getGUI()

  A set of controls to manipulate and control the display of data from the handler.

  Returns:
    Components used for control.

### removed

    void removed(java.awt.Container cont)

  Called by the LocationLayer when the Layer has been removed from the Map. The LocationHandler should clear out memory/CPU intensive resources.

  Parameters:
    `cont` - Container being removed from.

### setPrettyName

    void setPrettyName(java.lang.String prettyName)

  Set the name used in the GUI to represent this data set.

  Parameters:
    `prettyName` - A GUI pretty name.

### getPrettyName

    java.lang.String getPrettyName()

  Get the GUI pretty name for the data set retrieved by this LocationHandler.

  Returns:
    a pretty name for LocationHandler, to be used in the GUI.

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