Class TransformedFlattenedNestedListStreamBinding<T,U>
java.lang.Object
javafx.beans.binding.ObjectExpression<U>
javafx.beans.binding.ObjectBinding<U>
com.dlsc.gemsfx.binding.AbstractNestedListBinding<T,U>
com.dlsc.gemsfx.binding.TransformedFlattenedNestedListStreamBinding<T,U>
- Type Parameters:
T- the type of elements within the nested listsU- the type of the output produced by the transformation function
- All Implemented Interfaces:
javafx.beans.binding.Binding<U>, javafx.beans.Observable, javafx.beans.value.ObservableObjectValue<U>, javafx.beans.value.ObservableValue<U>
public class TransformedFlattenedNestedListStreamBinding<T,U>
extends AbstractNestedListBinding<T,U>
Binds a nested structure of
ObservableList<ObservableList<T>> to a transformed output U.
This class takes a nested list and applies a transformation function to a flattened version of that list,
producing a result of type U. This is useful for performing complex transformations on nested data
structures in a declarative way.-
Field Summary
Fields inherited from class AbstractNestedListBinding
source -
Constructor Summary
ConstructorsConstructorDescriptionTransformedFlattenedNestedListStreamBinding(javafx.collections.ObservableList<javafx.collections.ObservableList<T>> source, Function<Stream<T>, U> transformer) Constructs a new TransformedNestedListBinding with the specified source of nested observable lists and a transformation function. -
Method Summary
Modifier and TypeMethodDescriptionprotected UComputes the transformed value by applying the transformation function to the flattened source stream.Methods inherited from class AbstractNestedListBinding
dispose, flattenSource, initListenersMethods inherited from class javafx.beans.binding.ObjectBinding
addListener, addListener, allowValidation, bind, get, getDependencies, invalidate, isObserved, isValid, onInvalidating, removeListener, removeListener, toString, unbindMethods inherited from class javafx.beans.binding.ObjectExpression
asString, asString, asString, getValue, isEqualTo, isEqualTo, isNotEqualTo, isNotEqualTo, isNotNull, isNull, objectExpressionMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface javafx.beans.Observable
subscribeMethods inherited from interface javafx.beans.value.ObservableValue
flatMap, getValue, map, orElse, subscribe, subscribe, when
-
Constructor Details
-
TransformedFlattenedNestedListStreamBinding
public TransformedFlattenedNestedListStreamBinding(javafx.collections.ObservableList<javafx.collections.ObservableList<T>> source, Function<Stream<T>, U> transformer) Constructs a new TransformedNestedListBinding with the specified source of nested observable lists and a transformation function. The function will be applied to a flattened stream of the nested lists, allowing for the transformation of nested list elements into a single output value of typeU.- Parameters:
source- the observable list of observable lists that serves as the source for this bindingtransformer- a function that takes a flattened stream of elements of typeTand returns a transformed value of typeU
-
-
Method Details
-
computeValue
-