Package com.openinventor.inventor
Class SbEventHandler<E extends SbEventArg>
- java.lang.Object
-
- com.openinventor.inventor.SbEventHandler<E>
-
- Type Parameters:
E
- Type of event argument containing information about the event.
public abstract class SbEventHandler<E extends SbEventArg> extends java.lang.Object
Base abstract class for all event handler.
-
-
Constructor Summary
Constructors Constructor Description SbEventHandler()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
addEventListener(SbEventListener<E> listener)
Add a listener.void
clear()
boolean
removeEventListener(SbEventListener<E> listener)
Remove a listener.
-
-
-
Method Detail
-
addEventListener
public boolean addEventListener(SbEventListener<E> listener)
Add a listener.- Parameters:
listener
-- Returns:
-
removeEventListener
public boolean removeEventListener(SbEventListener<E> listener)
Remove a listener. Note that when using method reference the remove method cannot be used.ChangeListener
tabListener4 = this::tabChangeListener3; ChangeListener tabListener5 = this::tabChangeListener3 ; System.out.println(tabListener4.equals(tabListener5)); // <-- false - Parameters:
listener
-- Returns:
-
clear
public void clear()
-
-