Top Fields Constructors Methods
org.reactfx.value

pack-priv Class FlatMappedVar<T, U, O extends Property<U>>

Located in compilation unit of org.reactfx.value.FlatMapped.

extends FlatMapped<T, U, O extends Property<U>>
implements Var<U>
Class Inheritance
All Implemented Interfaces
org.reactfx.value.Var, javafx.beans.property.Property, javafx.beans.value.WritableValue, javafx.beans.property.ReadOnlyProperty, javafx.beans.value.ObservableValue, javafx.beans.Observable, org.reactfx.value.Val, org.reactfx.Observable

Field Summary

Modifier and TypeField and Description
private ObservableValue<? extends U>
private final ChangeListener<O>
Inherited from org.reactfx.value.FlatMapped:
src

Constructor Summary

AccessConstructor and Description
public
FlatMappedVar(ObservableValue<T> src, Function<? super T, O> f, U resetToOnUnbind)

public
FlatMappedVar(ObservableValue<T> src, Function<? super T, O> f)

private
FlatMappedVar(ObservableValue<T> src, Function<? super T, O> f, Consumer<O> onUnbind)

Method Summary

Modifier and TypeMethod and Description
public void
bind(ObservableValue<? extends U> other)

Implements javafx.beans.property.Property.bind.

Create a unidirection binding for this Property.

public boolean
isBound()

Implements javafx.beans.property.Property.isBound.

Can be used to check, if a Property is bound.

public void
setValue(U value)

Implements javafx.beans.value.WritableValue.setValue.

Set the wrapped value.

public void
unbind()

Implements javafx.beans.property.Property.unbind.

Remove the unidirectional binding for this Property.

Inherited from org.reactfx.value.FlatMapped:
computeValueconnect

Field Detail

boundToback to summary
private ObservableValue<? extends U> boundTo
srcListenerWhenBoundback to summary
private final ChangeListener<O> srcListenerWhenBound

Constructor Detail

FlatMappedVarback to summary
public FlatMappedVar(ObservableValue<T> src, Function<? super T, O> f, U resetToOnUnbind)
FlatMappedVarback to summary
public FlatMappedVar(ObservableValue<T> src, Function<? super T, O> f)
FlatMappedVarback to summary
private FlatMappedVar(ObservableValue<T> src, Function<? super T, O> f, Consumer<O> onUnbind)

Method Detail

bindback to summary
public void bind(ObservableValue<? extends U> other)

Implements javafx.beans.property.Property.bind.

Doc from javafx.beans.property.Property.bind.

Create a unidirection binding for this Property.

Note that JavaFX has all the bind calls implemented through weak listeners. This means the bound property can be garbage collected and stopped from being updated.

Annotations
@Override
isBoundback to summary
public boolean isBound()

Implements javafx.beans.property.Property.isBound.

Doc from javafx.beans.property.Property.isBound.

Can be used to check, if a Property is bound.

Annotations
@Override
setValueback to summary
public void setValue(U value)

Implements javafx.beans.value.WritableValue.setValue.

Doc from javafx.beans.value.WritableValue.setValue.

Set the wrapped value.

Annotations
@Override
unbindback to summary
public void unbind()

Implements javafx.beans.property.Property.unbind.

Doc from javafx.beans.property.Property.unbind.

Remove the unidirectional binding for this Property. If the Property is not bound, calling this method has no effect.

Annotations
@Override