T - the type of the eventline objectspublic class DefaultEventlineModel<T extends IEventlineObject> extends Object implements IEventlineModel<T>
IEventlineObject in a ArrayList.| Constructor and Description |
|---|
DefaultEventlineModel() |
| Modifier and Type | Method and Description |
|---|---|
void |
addEventlineModelListener(IEventlineModelListener l)
Adds an eventline model listener.
|
void |
addEventlineObject(T eventlineObject)
Adds a single object to the model.
|
void |
addEventlineObjects(Collection<T> eventlineObjects)
Adds a collection of eventline objects to the model.
|
void |
clearEventlineObjects()
Removes all eventline objects from the model.
|
protected void |
fireEventlineModelEvent(EventlineModelEvent evt)
Fires the given event by passing it to all listeners.
|
List<T> |
getEventlineObjects()
Returns the internal data structure used to store the eventline objects.
|
Iterator<T> |
getEventlineObjectsIterator(ITimeSpan span)
Returns an iterator for those eventline objects that are placed on the
eventline during the given span.
|
ITimeSpan |
getTimeSpan(T eventlineObject)
Returns the time span allocated to the given object.
|
void |
removeEventlineModelListener(IEventlineModelListener l)
Removes a listener from the eventline model.
|
void |
removeEventlineObject(T eventlineObject)
Removes a single object from the model.
|
void |
removeEventlineObjects(Collection<T> eventlineObjects)
Removes a collection of eventline objects from the model.
|
void |
setTimeSpan(T eventlineObject,
ITimeSpan span)
Sets a new time span on the given eventline object.
|
public Iterator<T> getEventlineObjectsIterator(ITimeSpan span)
IEventlineModelgetEventlineObjectsIterator in interface IEventlineModel<T extends IEventlineObject>span - the time span for which to return the timeline objectspublic ITimeSpan getTimeSpan(T eventlineObject)
IEventlineModelgetTimeSpan in interface IEventlineModel<T extends IEventlineObject>eventlineObject - the timeline objectpublic void setTimeSpan(T eventlineObject, ITimeSpan span)
eventlineObject - the eventline object that will get a new time span allocationspan - the new time spanpublic void addEventlineObject(T eventlineObject)
addEventlineObjects(Collection).eventlineObject - the object to addpublic void addEventlineObjects(Collection<T> eventlineObjects)
IEventlineModeladdEventlineObjects in interface IEventlineModel<T extends IEventlineObject>IEventlineModel.removeEventlineObjects(Collection)public void removeEventlineObject(T eventlineObject)
removeEventlineObjects(Collection).eventlineObject - the object to removepublic void removeEventlineObjects(Collection<T> eventlineObjects)
IEventlineModelremoveEventlineObjects in interface IEventlineModel<T extends IEventlineObject>IEventlineModel.addEventlineObjects(Collection)public void clearEventlineObjects()
public List<T> getEventlineObjects()
addEventlineObjects(Collection),
removeEventlineObjects(Collection)public void addEventlineModelListener(IEventlineModelListener l)
IEventlineModeladdEventlineModelListener in interface IEventlineModel<T extends IEventlineObject>l - the listener to addIEventlineModel.removeEventlineModelListener(IEventlineModelListener)public void removeEventlineModelListener(IEventlineModelListener l)
IEventlineModelremoveEventlineModelListener in interface IEventlineModel<T extends IEventlineObject>l - the listener to removeIEventlineModel.addEventlineModelListener(IEventlineModelListener)protected void fireEventlineModelEvent(EventlineModelEvent evt)
evt - the eventline model eventaddEventlineModelListener(IEventlineModelListener),
removeEventlineModelListener(IEventlineModelListener)Copyright © 2006–2020 Dirk Lemmermann Software & Consulting. All rights reserved.