T
- The parameter value type.public abstract static class IComputationStrategy.Parameter<T>
extends javafx.beans.property.ObjectPropertyBase<T>
IComputationStrategy
.Modifier and Type | Class and Description |
---|---|
static class |
IComputationStrategy.Parameter.Kind
Indicates whether the parameter value can be shared to compute
positions of all attached anchors or not.
|
Constructor and Description |
---|
Parameter(IComputationStrategy.Parameter.Kind kind)
Creates a new mandatory
IComputationStrategy.Parameter of the given kind. |
Parameter(IComputationStrategy.Parameter.Kind kind,
boolean optional)
Creates a new optional parameter of the given kind.
|
Modifier and Type | Method and Description |
---|---|
void |
bind(javafx.beans.value.ObservableValue<? extends T> newObservable) |
protected static <T extends IComputationStrategy.Parameter<?>> |
get(java.util.Collection<? extends IComputationStrategy.Parameter<?>> parameters,
java.lang.Class<T> parameterType)
Retrieves a parameter of the respective type from the set of given
parameters.
|
java.lang.Object |
getBean() |
IComputationStrategy.Parameter.Kind |
getKind()
Retrieves the
IComputationStrategy.Parameter.Kind of this parameter, which indicates whether
a single value may be shared to compute the positions of all attached
AnchorKey s or not. |
static IComputationStrategy.Parameter.Kind |
getKind(java.lang.Class<? extends IComputationStrategy.Parameter<?>> paramType)
Returns the
IComputationStrategy.Parameter.Kind returned by an instance of the given
IComputationStrategy.Parameter type. |
java.lang.String |
getName() |
void |
invalidateBinding()
If this parameter is bound, can be used to invalidate the underlying
binding, so that the value is re-computed.
|
boolean |
isOptional()
Indicates whether this parameter is optional
|
static boolean |
isOptional(java.lang.Class<? extends IComputationStrategy.Parameter<?>> paramType)
Returns
true if an instance of the given
IComputationStrategy.Parameter type is optional. |
void |
unbind() |
addListener, addListener, fireValueChangedEvent, get, invalidated, isBound, removeListener, removeListener, set, toString
bindBidirectional, setValue, unbindBidirectional
asString, asString, asString, getValue, isEqualTo, isEqualTo, isNotEqualTo, isNotEqualTo, isNotNull, isNull, objectExpression
public Parameter(IComputationStrategy.Parameter.Kind kind)
IComputationStrategy.Parameter
of the given kind.kind
- The parameter kind.public Parameter(IComputationStrategy.Parameter.Kind kind, boolean optional)
kind
- The parameter kin.optional
- Whether this parameter is optional or not.protected static <T extends IComputationStrategy.Parameter<?>> T get(java.util.Collection<? extends IComputationStrategy.Parameter<?>> parameters, java.lang.Class<T> parameterType)
T
- The runtime type of the parameter.parameters
- The set of parameters to search.parameterType
- The parameter typenull
.public static IComputationStrategy.Parameter.Kind getKind(java.lang.Class<? extends IComputationStrategy.Parameter<?>> paramType)
IComputationStrategy.Parameter.Kind
returned by an instance of the given
IComputationStrategy.Parameter
type.paramType
- The IComputationStrategy.Parameter
type for which to return the
IComputationStrategy.Parameter.Kind
.IComputationStrategy.Parameter.Kind
for the given IComputationStrategy.Parameter
type.public static boolean isOptional(java.lang.Class<? extends IComputationStrategy.Parameter<?>> paramType)
true
if an instance of the given
IComputationStrategy.Parameter
type is optional. Otherwise returns
false
.paramType
- The IComputationStrategy.Parameter
type for which to determine
optionality.true
if an instance of the given
IComputationStrategy.Parameter
type is optional, otherwise
false
.public void bind(javafx.beans.value.ObservableValue<? extends T> newObservable)
public java.lang.Object getBean()
public final IComputationStrategy.Parameter.Kind getKind()
IComputationStrategy.Parameter.Kind
of this parameter, which indicates whether
a single value may be shared to compute the positions of all attached
AnchorKey
s or not.IComputationStrategy.Parameter.Kind
.public java.lang.String getName()
public void invalidateBinding()
public final boolean isOptional()
true
if the parameter is optional,
false
otherwise.Copyright (c) 2014, 2016 itemis AG and others. All rights reserved.