ProjectionStack (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.proj
Class ProjectionStack

    java.lang.Object
      com.bbn.openmap.MapHandlerChild
          com.bbn.openmap.OMComponent
              com.bbn.openmap.proj.ProjectionStack

All Implemented Interfaces:
  ProjectionListener, LightMapHandlerChild, PropertyConsumer, java.awt.event.ActionListener, java.beans.beancontext.BeanContextChild, java.beans.beancontext.BeanContextMembershipListener, java.util.EventListener

    public class ProjectionStack

extends OMComponent
implements java.awt.event.ActionListener, ProjectionListener

Provides Projection Stack, to listen for projection changes and remember them as they pass by. As a Tool, it provides a GUI so that past projections can be retrieved, and, if a past projection is being displayed, a forward projection stack is activated to provide a path to get to the last projection set in the MapBean. ProjectionStackTriggers should hook themselves up to the ProjectionStack. The ProjectionStack is responsible for finding and connecting to the MapBean.

Nested Class Summary
`class` | `ProjectionStack.ProjHolder`

Field Summary
`static java.lang.String` | `BackProjCmd`
`protected java.util.Stack<ProjectionStack.ProjHolder>` | `backStack`
`static java.lang.String` | `ClearBackStackCmd`
`static java.lang.String` | `ClearForwardStackCmd`
`static java.lang.String` | `ClearStacksCmd`
`protected ProjectionStack.ProjHolder` | `currentProjection` The currentProjection should be the top item on the backStack.
`protected java.lang.String` | `currentProjectionID`
`static int` | `DEFAULT_MAX_SIZE`
`protected java.awt.Container` | `face`
`static java.lang.String` | `ForwardProjCmd`
`protected java.util.Stack<ProjectionStack.ProjHolder>` | `forwardStack`
`protected MapBean` | `mapBean`
`static int` | `REMEMBER_ALL`
`protected int` | `stackSize`
`protected ProjectionStackSupport` | `triggers`

Fields inherited from class com.bbn.openmap.OMComponent
`i18n, propertyPrefix`

Fields inherited from class com.bbn.openmap.MapHandlerChild
`beanContextChildSupport, isolated`

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

Constructor Summary
`ProjectionStack()` Create the projection submenu.

Method Summary
`void` | `actionPerformed(java.awt.event.ActionEvent ae)`
`void` | `addProjectionStackTrigger(ProjectionStackTrigger trigger)` ProjectionStackTriggers should call this method, and all will be well.
`protected ProjectionStack.ProjHolder` | `backPop()` Take a ProjHolder off the forwardStack, and push it on the backStack.
`void` | `clearStacks(boolean clearBackStack, boolean clearForwardStack)` Clear out the chosen projection stacks and fire an event to update the triggers on stack status.
`void` | `findAndInit(java.lang.Object someObj)` Look at the object received in a MapHandler status message and connect to it if necessary.
`void` | `findAndUndo(java.lang.Object someObj)` Look at the object received in a MapHandler status message and disconnect from it if necessary.
`void` | `fireStackStatus()`
`void` | `fireStackStatus(boolean enableBackButton, boolean enableForwardButton)`
`MapBean` | `getMapBean()`
`protected ProjectionFactory` | `getProjectionFactory(ProjectionEvent e)`
`protected ProjectionStack.ProjHolder` | `pop()` Take a ProjHolder off the backStack, and push it on the forward stack.
`void` | `projectionChanged(ProjectionEvent e)` The Map projection has changed.
`protected ProjectionStack.ProjHolder` | `push(ProjectionStack.ProjHolder proj)` Put a new ProjHolder on the backStack, to remember for later in case we need to back up.
`void` | `removeProjectionStackTrigger(ProjectionStackTrigger trigger)` ProjectionStackTriggers should call this method, and all will be well.
`void` | `setMapBean(MapBean map)`

Methods inherited from class com.bbn.openmap.OMComponent
`getProperties, getPropertyInfo, getPropertyPrefix, setProperties, setProperties, setPropertyPrefix`

Methods inherited from class com.bbn.openmap.MapHandlerChild
`addPropertyChangeListener, addVetoableChangeListener, childrenAdded, childrenRemoved, findAndInit, firePropertyChange, fireVetoableChange, getBeanContext, isIsolated, removePropertyChangeListener, removeVetoableChangeListener, setBeanContext, setIsolated`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### DEFAULT_MAX_SIZE

    public static final int DEFAULT_MAX_SIZE

See Also:
  Constant Field Values

### REMEMBER_ALL

    public static final int REMEMBER_ALL

See Also:
  Constant Field Values

### currentProjection

    protected transient ProjectionStack.ProjHolder currentProjection

  The currentProjection should be the top item on the backStack.

### currentProjectionID

    protected transient java.lang.String currentProjectionID

### face

    protected transient java.awt.Container face

### mapBean

    protected transient MapBean mapBean

### stackSize

    protected int stackSize

### BackProjCmd

    public static final transient java.lang.String BackProjCmd

See Also:
  Constant Field Values

### ForwardProjCmd

    public static final transient java.lang.String ForwardProjCmd

See Also:
  Constant Field Values

### ClearBackStackCmd

    public static final transient java.lang.String ClearBackStackCmd

See Also:
  Constant Field Values

### ClearForwardStackCmd

    public static final transient java.lang.String ClearForwardStackCmd

See Also:
  Constant Field Values

### ClearStacksCmd

    public static final transient java.lang.String ClearStacksCmd

See Also:
  Constant Field Values

### backStack

    protected java.util.Stack<ProjectionStack.ProjHolder> backStack

### forwardStack

    protected java.util.Stack<ProjectionStack.ProjHolder> forwardStack

### triggers

    protected ProjectionStackSupport triggers

Constructor Detail

### ProjectionStack

    public ProjectionStack()

  Create the projection submenu.

Method Detail

### setMapBean

    public void setMapBean(MapBean map)

### getMapBean

    public MapBean getMapBean()

### actionPerformed

    public void actionPerformed(java.awt.event.ActionEvent ae)

  Specified by:
    `actionPerformed` in interface `java.awt.event.ActionListener`

### getProjectionFactory

    protected ProjectionFactory getProjectionFactory(ProjectionEvent e)

### projectionChanged

    public void projectionChanged(ProjectionEvent e)

  The Map projection has changed.

  Specified by:
    `projectionChanged` in interface `ProjectionListener`
  Parameters:
    `e` - ProjectionEvent

### clearStacks

    public void clearStacks(boolean clearBackStack,
                            boolean clearForwardStack)

  Clear out the chosen projection stacks and fire an event to update the triggers on stack status.

  Parameters:
    `clearBackStack` - clear out the backward projection stack.
    `clearForwardStack` - clear out the forward projection stack.

### pop

    protected ProjectionStack.ProjHolder pop()

  Take a ProjHolder off the backStack, and push it on the forward stack.

  Returns:
    the ProjHolder pushed onto the forwardStack.

### backPop

    protected ProjectionStack.ProjHolder backPop()

  Take a ProjHolder off the forwardStack, and push it on the backStack.

  Returns:
    the ProjHolder pushed on the backStack.

### push

    protected ProjectionStack.ProjHolder push(ProjectionStack.ProjHolder proj)

  Put a new ProjHolder on the backStack, to remember for later in case we need to back up.

  Parameters:
    `proj` - ProjHolder.
  Returns:
    the ProjHolder pushed on the backStack.

### fireStackStatus

    public void fireStackStatus()

### fireStackStatus

    public void fireStackStatus(boolean enableBackButton,
                                boolean enableForwardButton)

### addProjectionStackTrigger

    public void addProjectionStackTrigger(ProjectionStackTrigger trigger)

  ProjectionStackTriggers should call this method, and all will be well.

### removeProjectionStackTrigger

    public void removeProjectionStackTrigger(ProjectionStackTrigger trigger)

  ProjectionStackTriggers should call this method, and all will be well.

### findAndUndo

    public void findAndUndo(java.lang.Object someObj)

  Look at the object received in a MapHandler status message and disconnect from it if necessary.

  Specified by:
    `findAndUndo` in interface `LightMapHandlerChild`
  Overrides:
    `findAndUndo` in class `MapHandlerChild`

### findAndInit

    public void findAndInit(java.lang.Object someObj)

  Look at the object received in a MapHandler status message and connect to it if necessary.

  Specified by:
    `findAndInit` in interface `LightMapHandlerChild`
  Overrides:
    `findAndInit` in class `MapHandlerChild`

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