Top Fields Methods
org.reactfx.inhibeans

public Interface Observable

extends Observable, Guardian
Known Direct Subinterfaces
org.reactfx.inhibeans.collection.ObservableList, org.reactfx.inhibeans.value.ObservableValue
Annotations
@Deprecated
Imports
java.util.function.Supplier, org.reactfx.Guard, .Guardian, .Suspendable

Deprecated

Superseded by Suspendable.

Field Summary

Inherited from org.reactfx.Guardian:
EMPTY

Method Summary

Modifier and TypeMethod and Description
public Guard

Returns:

a Guard instance that can be released to resume the delivery of invalidation and change events. If this observable has been invalidated one or more times before the guard is released, a single notification is passed to invalidation and change listeners of this observable. The returned Guard is AutoCloseable, which makes it convenient to use in try-with-resources.
block
()

Prevents invalidation and change events from being emitted, until the returned guard is released.

public default void
blockWhile(Runnable r)

Runs the given computation, making sure the invalidation and change events are blocked.

public default <T> T
blockWhile(Supplier<T> f)

Runs the given computation, making sure the invalidation and change events are blocked.

public default Guard
guard()

Implements org.reactfx.Guardian.guard.

Equivalent to block().

Inherited from javafx.beans.Observable:
addListenerremoveListenersubscribe
Inherited from org.reactfx.Guardian:
combineguardWhileguardWhile

Method Detail

blockback to summary
public Guard block()

Prevents invalidation and change events from being emitted, until the returned guard is released.

Returns:Guard

a Guard instance that can be released to resume the delivery of invalidation and change events. If this observable has been invalidated one or more times before the guard is released, a single notification is passed to invalidation and change listeners of this observable. The returned Guard is AutoCloseable, which makes it convenient to use in try-with-resources.

blockWhileback to summary
public default void blockWhile(Runnable r)

Runs the given computation, making sure the invalidation and change events are blocked. When done, previous blocked state is restored.

Equivalent to

try(Guard g = block()) {
    r.run();
}
blockWhileback to summary
public default <T> T blockWhile(Supplier<T> f)

Runs the given computation, making sure the invalidation and change events are blocked. When done, previous blocked state is restored.

T t = this.blockWhile(f);
is equivalent to
T t;
try(Guard g = block()) {
    t = f.get();
}
guardback to summary
public default Guard guard()

Implements org.reactfx.Guardian.guard.

Equivalent to block().

Annotations
@Override