|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface ControlEngine
Engine for controllers and service objects.
This engine allows service tier objects to communicate with the view.
| Method Summary | ||
|---|---|---|
|
addActionHandler(ActionId<T> actionId,
ActionHandler<T> actionHandler)
|
|
void |
fireEvent(EventId<EmptyEvent> eventId)
Fires an event and allows all event listeners to handle it. |
|
|
fireEvent(EventId<T> eventId,
T argument)
Fires the event with an argument passed to listeners. |
|
|
fireValueEvent(EventId<ValueEvent<T>> eventId,
T argument)
Convenience method that fires a value event (a wrapper of a simple class into an eventObject). |
|
|
get(ModelId<T> modelId)
Gets a value from the engine model repository. |
|
|
removeActionHandler(ActionId<T> actionId)
|
|
|
set(ModelId<T> modelId,
T value,
EventId<ValueEvent<T>> event)
|
|
| Methods inherited from interface org.asmatron.messengine.EngineController |
|---|
start, stop |
| Method Detail |
|---|
void fireEvent(EventId<EmptyEvent> eventId)
eventId - The id of the event (must be an EmptyEvent)
<T extends EventObject> void fireEvent(EventId<T> eventId,
T argument)
T - The type of the argument, it must extend the EventObject class.eventId - The id of the eventargument - The argument of matching T type that will be passed to event
listeners
<T> void fireValueEvent(EventId<ValueEvent<T>> eventId,
T argument)
T - Anything that we want to send to eventListeners.eventId - The id of the event (must be a ValueEvent)argument - the argument that will be wrapped on a valueEvent<T> T get(ModelId<T> modelId)
T - The type of the value storedmodelId - the id of the model variable stored in the engine
<T> void set(ModelId<T> modelId,
T value,
EventId<ValueEvent<T>> event)
<T extends ActionObject> void addActionHandler(ActionId<T> actionId,
ActionHandler<T> actionHandler)
<T extends ActionObject> void removeActionHandler(ActionId<T> actionId)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||