net.sf.javagimmicks.event.Observable Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of gimmicks Show documentation
Show all versions of gimmicks Show documentation
Utility classes, APIs and tools for Java
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