public class DefaultLayerContainerSelectionModel extends Object implements ILayerContainerSelectionModel
ILayerContainerSelectionModel
.Constructor and Description |
---|
DefaultLayerContainerSelectionModel() |
Modifier and Type | Method and Description |
---|---|
void |
addLayerContainerSelectionModelListener(ILayerContainerSelectionModelListener l)
Adds a listener to the selection model.
|
void |
addSelectedTimeSpan(Object node,
ITimeSpan span)
Adds a time span to the list of selected time spans of the given tree
table node object.
|
void |
clearSelectedTimeSpans()
Removes all selected time spans from the selection model.
|
void |
clearSelectedTimeSpans(Object node)
Removes all of those selected time spans that belong to the given tree
node object.
|
protected void |
fireTimeSpansAdded(Object node,
List<ITimeSpan> spans)
Sends a
TimeSpanSelectionEvent to all listeners informing them
that time spans have been added to the selection model. |
protected void |
fireTimeSpansRemoved(Object node,
List<ITimeSpan> spans)
Sends a
TimeSpanSelectionEvent to all listeners informing them
that time spans have been removed from the selection model. |
Iterator<ITimeSpan> |
getSelectedTimeSpans(Object owner,
ITimeSpan span)
Returns an iterator for iterating over the list of selected time spans of
the given node within the given time span.
|
boolean |
isEmpty()
Checks whether the selection model contains any selections at all.
|
boolean |
isEmpty(Object node)
Checks whether the selection model contains any selections for the given
tree node object.
|
boolean |
isSelected(Object node,
ITimeSpan span)
Returns TRUE if the given time span is currently selected on the given
tree table node.
|
void |
removeLayerContainerSelectionModelListener(ILayerContainerSelectionModelListener l)
Removes a listener from the selection model.
|
void |
removeSelectedTimeSpan(Object node,
ITimeSpan removedSpan)
Removes a time span from the list of selected time spans of the given
tree table node object.
|
public boolean isEmpty()
ILayerContainerSelectionModel
isEmpty
in interface ILayerContainerSelectionModel
public boolean isEmpty(Object node)
ILayerContainerSelectionModel
isEmpty
in interface ILayerContainerSelectionModel
node
- the node to check for selectionspublic void clearSelectedTimeSpans()
ILayerContainerSelectionModel
public void clearSelectedTimeSpans(Object node)
ILayerContainerSelectionModel
clearSelectedTimeSpans
in interface ILayerContainerSelectionModel
node
- the tree table node objectILayerContainerSelectionModel.clearSelectedTimeSpans()
,
ILayerContainerSelectionModel.removeSelectedTimeSpan(Object, ITimeSpan)
public void addSelectedTimeSpan(Object node, ITimeSpan span)
ILayerContainerSelectionModel
addSelectedTimeSpan
in interface ILayerContainerSelectionModel
node
- the tree table node objectspan
- the time span to addILayerContainerSelectionModel.removeSelectedTimeSpan(Object, ITimeSpan)
public void removeSelectedTimeSpan(Object node, ITimeSpan removedSpan)
ILayerContainerSelectionModel
removeSelectedTimeSpan
in interface ILayerContainerSelectionModel
node
- the tree table node objectremovedSpan
- the time span to removeILayerContainerSelectionModel.addSelectedTimeSpan(Object, ITimeSpan)
public Iterator<ITimeSpan> getSelectedTimeSpans(Object owner, ITimeSpan span)
ILayerContainerSelectionModel
getSelectedTimeSpans
in interface ILayerContainerSelectionModel
owner
- the tree table node objectspan
- the time span for which an iterator gets createdpublic boolean isSelected(Object node, ITimeSpan span)
ILayerContainerSelectionModel
isSelected
in interface ILayerContainerSelectionModel
node
- the tree table node objectspan
- the time span to checkITimeSpan.contains(ITimeSpan)
public void addLayerContainerSelectionModelListener(ILayerContainerSelectionModelListener l)
ILayerContainerSelectionModel
addLayerContainerSelectionModelListener
in interface ILayerContainerSelectionModel
l
- the listener to addILayerContainerSelectionModel.removeLayerContainerSelectionModelListener(ILayerContainerSelectionModelListener)
public void removeLayerContainerSelectionModelListener(ILayerContainerSelectionModelListener l)
ILayerContainerSelectionModel
removeLayerContainerSelectionModelListener
in interface ILayerContainerSelectionModel
l
- the listener to removeILayerContainerSelectionModel.addLayerContainerSelectionModelListener(ILayerContainerSelectionModelListener)
protected void fireTimeSpansAdded(Object node, List<ITimeSpan> spans)
TimeSpanSelectionEvent
to all listeners informing them
that time spans have been added to the selection model.node
- the tree node on which time spans were added to the selectionspans
- the time spans that were addedprotected void fireTimeSpansRemoved(Object node, List<ITimeSpan> spans)
TimeSpanSelectionEvent
to all listeners informing them
that time spans have been removed from the selection model.node
- the tree node on which time spans were removed from the
selectionspans
- the time spans that were removedCopyright © 2006–2016 Dirk Lemmermann Software & Consulting. All rights reserved.