Class ActivatableSupport


  • public class ActivatableSupport
    extends java.lang.Object
    A support class to manage the activeProperty state for a source IActivatable. It offers all methods defined by IActivatable, while not formally implementing the interface, and can thus be used by a source IActivatable as a delegate.
    • Method Detail

      • activate

        public void activate​(java.lang.Runnable preActivationCallback,
                             java.lang.Runnable postActivationCallback)
        Activates this ActivatableSupport if it is not yet active.
        Parameters:
        preActivationCallback - An optional callback that is executed before the active state is set.
        postActivationCallback - An optional callback that is executed after the active state has been set.
        See Also:
        IActivatable.activate()
      • activeProperty

        public javafx.beans.property.ReadOnlyBooleanProperty activeProperty()
        Returns a ReadOnlyBooleanProperty that reflects the activeProperty state of this ActivatableSupport.
        Returns:
        A read-only boolean Property representing the activeProperty state.
      • deactivate

        public void deactivate​(java.lang.Runnable preDeactivationCallback,
                               java.lang.Runnable postDeactivationCallback)
        Deactivates this ActivatableSupport if it is not yet inactive.
        Parameters:
        preDeactivationCallback - An optional callback that is executed before the active state is unset.
        postDeactivationCallback - An optional callback that is executed after the active state has been unset.
        See Also:
        IActivatable.deactivate()