Module VirtualizedFX
Class InvalidationAction<T>
java.lang.Object
io.github.palexdev.virtualizedfx.controls.behavior.actions.InvalidationAction<T>
- All Implemented Interfaces:
DisposableAction
An
InvalidationAction
is a convenience bean which implements DisposableAction
used by BehaviorBase
to register an InvalidationListener
on a certain ObservableValue
and dispose it once it's not needed anymore.-
Constructor Summary
ConstructorsConstructorDescriptionInvalidationAction
(ObservableValue<T> observable, InvalidationListener listener) -
Method Summary
Modifier and TypeMethodDescriptionvoid
dispose()
Disposes this action.static <T> InvalidationAction<T>
of
(ObservableValue<T> observable, InvalidationListener listener) Equivalent toInvalidationAction(ObservableValue, InvalidationListener)
but this also adds the listener to the observable already.
-
Constructor Details
-
InvalidationAction
-
-
Method Details
-
of
public static <T> InvalidationAction<T> of(ObservableValue<T> observable, InvalidationListener listener) Equivalent toInvalidationAction(ObservableValue, InvalidationListener)
but this also adds the listener to the observable already. -
dispose
public void dispose()Disposes this action. Removes theInvalidationListener
from the observable then sets both the fields to null.- Specified by:
dispose
in interfaceDisposableAction
-
getObservable
-
getListener
-