ProjectionChangePolicy (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.policy
Interface ProjectionChangePolicy

All Known Implementing Classes:
  AbstractProjectionChangePolicy, ListResetPCPolicy, NullProjectionChangePolicy, StandardPCPolicy

    public interface ProjectionChangePolicy

A ProjectionChangePolicy is a policy object that determines how an OMGraphicHandler layer reacts to a projectionChanged() method call. The OMGraphicHandlerLayer has been written to consult this object to control that activity. The reaction could include clearing out the current OMGraphicList or keeping it, or launching a SwingWorker with a doPrepare() call on the layer to have the layer's prepare() method called.

Method Summary
`OMGraphicHandlerLayer` | `getLayer()`
`void` | `projectionChanged(ProjectionEvent pe)` The method that is called when the projection changes.
`void` | `setLayer(OMGraphicHandlerLayer layer)`
`void` | `workerComplete(OMGraphicList aList)` The method that gets called when the SwingWorker thread finishes.

Method Detail

### setLayer

    void setLayer(OMGraphicHandlerLayer layer)

  Parameters:
    `layer` - the OMGraphicHandlerLayer the policy is working for.

### getLayer

    OMGraphicHandlerLayer getLayer()

  Returns:
    the OMGraphicHandlerLayer the policy is working for.

### projectionChanged

    void projectionChanged(ProjectionEvent pe)

  The method that is called when the projection changes. The ProjectionChangePolicy should modify the OMGraphicList and do other functions as dictated by the policy, like starting threads to gather data and generating new OMGraphics for the layer.

  Parameters:
    `pe` - the ProjectionEvent received by the layer.

### workerComplete

    void workerComplete(OMGraphicList aList)

  The method that gets called when the SwingWorker thread finishes. The OMGraphicList is what is getting returned from the prepare() method on the layer, so it's most likely that this list should be set on the layer and repaint should be called on the layer.

  Parameters:
    `aList` - the OMGraphicList returned from the OMGraphicHandlerLayer prepare method via the SwingWorker.

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