net.refractions.udig.project
Interface IEditManager


public interface IEditManager

Defines and implements controllers a map. The EditManager is the central piece and has the following functionality:

Transactions and locks are also part of map core.

Since:
0.1
Author:
jeichar

Method Summary
 void addListener(IEditManagerListener listener)
          Adds a EditManager Listener
 boolean containsListener(IEditManagerListener listener)
          Checks containment of the spesified EditManager listener in the list of already existing listeners.
 Feature getEditFeature()
          Gets the Feature that that is currently being edited.
 ILayer getEditLayer()
          The layer that contains the edit features.
 IMap getMap()
          Returns the map this EditManager is associated with
 ILayer getSelectedLayer()
          Returns the layer that is "currently" selected.
 boolean isEditing()
          Returns true if there is a currently active transaction (editing has occured and not been committed).
 boolean isEditLayerLocked()
          Indicates whether the editlayer can be changed.
 void removeListener(IEditManagerListener listener)
          Removes a EditManager Listener
 

Method Detail

getMap

IMap getMap()
Returns the map this EditManager is associated with

Returns:
the map this EditManager is associated with

getEditFeature

Feature getEditFeature()
Gets the Feature that that is currently being edited.

Returns null if there is currently no edit feature. This is different from the current selection. Each layer has a selection that may contain many features but there is only only feature that can be editted at one time.

Returns:
the Feature that that is currently being edited.

getEditLayer

ILayer getEditLayer()
The layer that contains the edit features. Often feature edit commands will require the layer that contains the Edit feature so that the feature may be editted.

Returns:
the layer that contains the edit feature in its feature store.

isEditLayerLocked

boolean isEditLayerLocked()
Indicates whether the editlayer can be changed.

Returns:
true if the current editlayer is locked and cannot be changed.

getSelectedLayer

ILayer getSelectedLayer()
Returns the layer that is "currently" selected. The workbench is monitored for changes to selection and this will reflect that layer.

Returns:
the layer that is "currently" selected

isEditing

boolean isEditing()
Returns true if there is a currently active transaction (editing has occured and not been committed). false is returned if there is no current transaction. If false is returned it is understood that no editing is occurring.

Returns:
Returns true if there is a currently active transaction. false is returned if there is no current transaction.

addListener

void addListener(IEditManagerListener listener)
Adds a EditManager Listener

Parameters:
listener - the new listener.

removeListener

void removeListener(IEditManagerListener listener)
Removes a EditManager Listener

Parameters:
listener - the listener to remove

containsListener

boolean containsListener(IEditManagerListener listener)
Checks containment of the spesified EditManager listener in the list of already existing listeners.

Parameters:
listener -
Returns: