public abstract class ValBase<T> extends ObservableBase<java.util.function.Consumer<? super T>,T> implements ProperVal<T>
| Constructor and Description |
|---|
ValBase() |
| Modifier and Type | Method and Description |
|---|---|
protected abstract T |
computeValue() |
protected abstract Subscription |
connect()
Implementation of this method should start observing inputs.
|
T |
getValue() |
protected void |
invalidate() |
protected void |
newObserver(java.util.function.Consumer<? super T> oldValueObserver)
Called for each new observer.
|
protected Subscription |
observeInputs()
Starts observing this observable's input(s), if any.
|
addObserver, enqueueNotifications, equals, forEachObserver, getObserverCount, hashCode, isObservingInputs, notifyObservers, notifyObservers, observe, removeObserver, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitdefaultNotificationAccumulatoraddInvalidationObserver, addListener, addListener, animate, animate, animate, animate, animate, animate, asList, asVar, changes, combine, combine, combine, combine, combine, conditionOn, conditionOn, conditionOnShowing, conditionOnShowing, constant, create, create, filter, filter, flatMap, flatMap, getOpt, getOrElse, getOrSupply, getOrThrow, ifPresent, invalidations, isEmpty, isPresent, map, map, mapDynamic, mapDynamic, observeChanges, observeChanges, observeInvalidations, observeInvalidations, orElse, orElse, orElseConst, orElseConst, pin, removeInvalidationObserver, removeListener, removeListener, selectVar, selectVar, selectVar, selectVar, showingProperty, suspendable, suspendable, values, wrapdefaultEquals, defaultHashCode, defaultToString, notifyObserversaddObserver, observe, removeObserverpublic final T getValue()
getValue in interface javafx.beans.value.ObservableValue<T>protected final Subscription observeInputs()
ObservableBaseObservableBase.newObserver(Object)
is called for the first observer.observeInputs in class ObservableBase<java.util.function.Consumer<? super T>,T>protected final void invalidate()
protected final void newObserver(java.util.function.Consumer<? super T> oldValueObserver)
ObservableBaseThis method is called after the
ObservableBase.observeInputs() method.
newObserver in class ObservableBase<java.util.function.Consumer<? super T>,T>protected abstract Subscription connect()
invalidate() to notify
observers of this Val. By the time of calling invalidate(), the input observer must have already updated any internal
state of this Val, so that a subsequent call to computeValue() returns the current value of this Val.protected abstract T computeValue()