Interface Toggle
- All Superinterfaces:
javafx.beans.Observable, Observable<Consumer<? super Boolean>>, javafx.beans.value.ObservableValue<Boolean>, Suspendable, Val<Boolean>
- All Known Implementing Classes:
SuspendableBoolean, SuspendableNo, SuspendableYes, ToggleFromVal
Observable boolean that changes value when suspended.
Which boolean value is the value of the base state and which is the value
of the suspended state depends on the implementation.
-
Method Summary
Static MethodsModifier and TypeMethodDescriptionstatic Togglefrom(javafx.beans.value.ObservableValue<Boolean> obs, Suspendable suspender) Creates a Toggle view of an observable boolean and a Suspendable whose suspension causes the boolean value to switch.Methods inherited from interface Observable
addObserver, observe, removeObserverMethods inherited from interface javafx.beans.value.ObservableValue
getValueMethods inherited from interface Suspendable
suspend, suspendWhen, suspendWhile, suspendWhileMethods inherited from interface Val
addInvalidationObserver, addListener, addListener, animate, animate, asList, asVar, changes, conditionOn, conditionOnShowing, filter, flatMap, getOpt, getOrElse, getOrSupply, getOrThrow, ifPresent, invalidations, isEmpty, isPresent, map, mapDynamic, observeChanges, observeInvalidations, orElse, orElseConst, pin, removeInvalidationObserver, removeListener, removeListener, selectVar, selectVar, suspendable, values
-
Method Details
-
from
Creates a Toggle view of an observable boolean and a Suspendable whose suspension causes the boolean value to switch.- Parameters:
obs- boolean value that indicates suspension ofsuspender.suspender- Assumed to switch the value ofobswhen suspended and switch back when resumed, unless there are other suspenders keeping it in the value corresponding to the suspended state.
-