|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.cau.cs.kieler.sim.kiem.config.extension.KiemEventListener
public final class KiemEventListener
Listens to all events from the main KIEM Plugin and handles file related events.
Constructor Summary | |
---|---|
KiemEventListener()
Creates a new FileEventListener. |
Method Summary | |
---|---|
static KiemEventListener |
getInstance()
Returns the instance of the file event listener. |
void |
notifyEvent(KiemEvent event)
This is the basic notify method that is called by KIEM whenever an event occurs for which this EventListener is registered (see IKiemEventListener.provideEventOfInterest() ). |
KiemEvent |
provideEventOfInterest()
Return a KiemEvent type (integer value) that represents a number of events this component wants to listen to. |
void |
resetLoadImminent()
Notify the listener that the load failed and it should not expect it. |
void |
resetSaveImminent()
Notify the listener that the save failed and it should not expect it. |
void |
setLoadImminent()
Notify the listener that the plugin will report a load soon but the listener should ignore it as it was plugin-triggered. |
void |
setSaveImminent()
Notify the listener that the plugin will report a save soon but the listener should ignore it as it was plugin-triggered. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public KiemEventListener()
Method Detail |
---|
public static KiemEventListener getInstance()
public void notifyEvent(KiemEvent event)
IKiemEventListener.provideEventOfInterest()
).
notifyEvent
in interface IKiemEventListener
event
- the KiemEvent with additional attached information, depending
on the specific eventpublic KiemEvent provideEventOfInterest()
Return a KiemEvent type (integer value) that represents a number of events this component wants to listen to.
A KiemEvent can be a combination of several events. The simplest way to register for two events that e.g., indicate a step-command and the removal of the component is to have the following code:
public KiemEvent provideEventOfInterest() {
int[] events = {CMD_STEP, DELETED}
return new KiemEvent(events);
}
provideEventOfInterest
in interface IKiemEventListener
public void setLoadImminent()
public void resetLoadImminent()
public void setSaveImminent()
public void resetSaveImminent()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |