org.jgap.event
Interface IEventManager
-
- All Superinterfaces:
- java.io.Serializable
- All Known Implementing Classes:
- EventManager
public interface IEventManager extends java.io.SerializableInterface for event managers (e.g., see class EventManager).- Since:
- 2.6
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method and Description voidaddEventListener(java.lang.String a_eventName, GeneticEventListener a_eventListenerToAdd)Adds a new listener that will be notified when the event represented by the given name is fired.voidfireGeneticEvent(GeneticEvent a_eventToFire)Fires a genetic event.voidremoveEventListener(java.lang.String a_eventName, GeneticEventListener a_eventListenerToRemove)Removes the given listener from subscription of the indicated event.
-
-
-
Method Detail
-
addEventListener
void addEventListener(java.lang.String a_eventName, GeneticEventListener a_eventListenerToAdd)Adds a new listener that will be notified when the event represented by the given name is fired.- Parameters:
a_eventName- the name of the event to which the given listener should be subscribed. Standard events are represented by constants in the GeneticEvent classa_eventListenerToAdd- the genetic listener to subscribe to notifications of the given event- Since:
- 2.6 (since 1.0 in EventManager)
-
removeEventListener
void removeEventListener(java.lang.String a_eventName, GeneticEventListener a_eventListenerToRemove)Removes the given listener from subscription of the indicated event. The listener will no longer be notified when the given event occurs.- Parameters:
a_eventName- the name of the event to which the given listener should be removed. Standard events are represented by constants in the GeneticEvent classa_eventListenerToRemove- the genetic listener to unsubscribe from notifications of the given event- Since:
- 2.6 (since 1.0 in EventManager)
-
fireGeneticEvent
void fireGeneticEvent(GeneticEvent a_eventToFire)
Fires a genetic event. All subscribers of that particular event type (as determined by the name of the event) will be notified of it having been fired.- Parameters:
a_eventToFire- the representation of the genetic event to fire- Since:
- 2.6 (since 1.0 in EventManager)
-
-
DMelt 3.0 © DataMelt by jWork.ORG