public class TLcdModelContainerEvent extends ALcdDispatchableEvent
TLcdModelContainerEvent
implements dispatchable events
on a ILcdModelContainer
.Modifier and Type | Field and Description |
---|---|
static int |
CONTENT_CHANGED
Part of the event ID when the ModelContainer contents changed.
|
static int |
MODEL_ADDED
Part of the event ID when an object has been added to the container.
|
static int |
MODEL_REMOVED
Part of the event ID when an object has been deleted from the container.
|
source
Constructor and Description |
---|
TLcdModelContainerEvent(ILcdModelContainer aModelContainer,
int aID,
ILcdModel aModel)
An event that indicates that aModelContainer has changed in aID manner, which involves aModel.
|
Modifier and Type | Method and Description |
---|---|
void |
dispatch(EventListener listener)
Sends this
ILcdDispatchableEvent to the given listener. |
int |
getID()
Returns the ID indicating the type of event.
|
ILcdModel |
getModel()
Returns the model that caused the change to the model container.
|
ILcdModelContainer |
getModelContainer()
Returns the model container that has changed.
|
String |
toString() |
paramString
getSource
public static final int CONTENT_CHANGED
public static final int MODEL_ADDED
public static final int MODEL_REMOVED
public TLcdModelContainerEvent(ILcdModelContainer aModelContainer, int aID, ILcdModel aModel)
aModelContainer
- the model container that has changed.aID
- description of the change to the model container. Compare to CONTENT_CHANGED,
MODEL_ADDED, MODEL_REMOVED.aModel
- the model which caused the change to the model container.public void dispatch(EventListener listener)
ILcdDispatchableEvent
ILcdDispatchableEvent
to the given listener.dispatch
in interface ILcdDispatchableEvent
dispatch
in class ALcdDispatchableEvent
listener
- the listener that will receive this ILcdDispatchableEvent
.public int getID()
public ILcdModel getModel()
public ILcdModelContainer getModelContainer()
public String toString()
toString
in class ALcdDispatchableEvent