All Downloads are FREE. Search and download functionalities are using the official Maven repository.

net.sf.javagimmicks.event.Observable Maven / Gradle / Ivy

There is a newer version: 0.99-alpha1
Show newest version
package net.sf.javagimmicks.event;

/**
 * A generic interfaces the describes an observable object that is able to fire
 * and report {@link Event}s to any interested {@link EventListener}.
 * 
 * @param 
 *           the {@link Event} type that will be fired
 */
public interface Observable>
{
   /**
    * Adds a new {@link EventListener} (or sub-type) to this {@link Observable}
    * 
    * @param listener
    *           the {@link EventListener} (or sub-type) to add
    * @param 
    *           the type of {@link EventListener} to add
    */
   > void addEventListener(L listener);

   /**
    * Removes a registered {@link EventListener} (or sub-type) from this
    * {@link Observable}
    * 
    * @param listener
    *           the {@link EventListener} (or sub-type) to remove
    * @param 
    *           the type of {@link EventListener} to add
    */
   > void removeEventListener(L listener);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy