StyleablePropertyFactory as a static member, as shown below, is recommended.
public final class MyButton extends Button {
private static final StyleablePropertyFactory<MyButton> FACTORY = new StyleablePropertyFactory<>(Button.getClassCssMetaData());
MyButton(String labelText) {
super(labelText);
getStyleClass().add("my-button");
}
// Typical JavaFX property implementation
public ObservableValue<Boolean> selectedProperty() { return (ObservableValue<Boolean>)selected; }
public final boolean isSelected() { return selected.getValue(); }
public final void setSelected(boolean isSelected) { selected.setValue(isSelected); }
// StyleableProperty implementation reduced to one line
private final StyleableProperty<Boolean> selected =
FACTORY.createStyleableBooleanProperty(this, "selected", "-my-selected", s -> s.selected);
@Override
public List<CssMetaData<? extends Styleable, ?>> getControlCssMetaData() {
return FACTORY.getCssMetaData();
}
}
The example above is the simplest use of StyleablePropertyFactory. But, this use does not provide the
static CssMetaData that is useful for getClassCssMetaData(), which is described in the javadoc for
CssMetaData. Static CssMetaData can, however, be created via StyleablePropertyFactory methods
and will be returned by the methods which create StyleableProperty instances, as the example below illustrates.
Note that the static method getClassCssMetaData() is a convention used throughout the JavaFX code base
but the getClassCssMetaData() method itself is not used at runtime.
public final class MyButton extends Button {
private static final StyleablePropertyFactory<MyButton> FACTORY =
new StyleablePropertyFactory<>(Button.getClassCssMetaData());
private static final CssMetaData<MyButton, Boolean> SELECTED =
FACTORY.createBooleanCssMetaData("-my-selected", s -> s.selected, false, false);
MyButton(String labelText) {
super(labelText);
getStyleClass().add("my-button");
}
// Typical JavaFX property implementation
public ObservableValue<Boolean> selectedProperty() { return (ObservableValue<Boolean>)selected; }
public final boolean isSelected() { return selected.getValue(); }
public final void setSelected(boolean isSelected) { selected.setValue(isSelected); }
// StyleableProperty implementation reduced to one line
private final StyleableProperty<Boolean> selected =
new SimpleStyleableBooleanProperty(SELECTED, this, "selected");
public static List<CssMetaData<? extends Styleable, ?>> getClassCssMetaData() {
return FACTORY.getCssMetaData();
}
@Override
public List<CssMetaData<? extends Styleable, ?>> getControlCssMetaData() {
return FACTORY.getCssMetaData();
}
}
The same can be accomplished with an inner-class. The previous example called new SimpleStyleableBooleanProperty
to create the selected property. This example uses the factory to access the CssMetaData
that was created along with the anonymous inner-class. For all intents and purposes, the two examples are the same.
public final class MyButton extends Button {
private static CssMetaData<MyButton, Boolean> SELECTED;
private static final StyleablePropertyFactory<MyButton> FACTORY =
new StyleablePropertyFactory<>(Button.getClassCssMetaData()) {
{
SELECTED = createBooleanCssMetaData("-my-selected", s -> s.selected, false, false);
}
};
MyButton(String labelText) {
super(labelText);
getStyleClass().add("my-button");
}
// Typical JavaFX property implementation
public ObservableValue<Boolean> selectedProperty() { return (ObservableValue<Boolean>)selected; }
public final boolean isSelected() { return selected.getValue(); }
public final void setSelected(boolean isSelected) { selected.setValue(isSelected); }
// StyleableProperty implementation reduced to one line
private final StyleableProperty<Boolean> selected =
new SimpleStyleableBooleanProperty(SELECTED, "selected", "my-selected");
public static List<CssMetaData<? extends Styleable, ?>> getClassCssMetaData() {
return FACTORY.getCssMetaData();
}
@Override
public List<CssMetaData<? extends Styleable, ?>> getControlCssMetaData() {
return FACTORY.getCssMetaData();
}
}
Caveats:
The only option for creating a StyleableProperty with a number value is to create a StyleableProperty<Number>. The return value from thegetValue() method of the StyleableProperty is a Number. Therefore,
the get method of the JavaFX property needs to call the correct value method for the return type.
For example,
public ObservableValue<Double> offsetProperty() { return (ObservableValue<Double>)offset; }
public Double getOffset() { return offset.getValue().doubleValue(); }
public void setOffset(Double value) { offset.setValue(value); }
private final StyleableProperty<Number> offset = FACTORY.createStyleableNumberProperty(this, "offset", "-my-offset", s -> ((MyButton)s).offset);
| Modifier and Type | Class and Description |
|---|---|
| private static class |
| Modifier and Type | Field and Description |
|---|---|
| private final List | |
| private final Map | |
| private final List |
| Access | Constructor and Description |
|---|---|
| public | StyleablePropertyFactory(List<CssMetaData<? extends Styleable, ?>>
The CssMetaData of the parent class of <S>, or null. parentCssMetaData)The constructor is passed the CssMetaData of the parent class of <S>, typically by calling the
static |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv void | |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Boolean>> A function that returns the StyleableProperty<Boolean> that corresponds to this CssMetaData. function, final boolean The initial value of the property. CSS may reset the property to this value. initialValue, final boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a CssMetaData<S, Boolean> with initial value, and inherit flag. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Boolean>> A function that returns the StyleableProperty<Boolean> that corresponds to this CssMetaData. function, final boolean The initial value of the property. CSS may reset the property to this value. initialValue)Create a CssMetaData<S, Boolean> with initial value, and inherit flag defaulting to false. |
| public final CssMetaData | Returns: a CssMetaData created with false initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Boolean>> A function that returns the StyleableProperty<Boolean> that corresponds to this CssMetaData. function)Create a CssMetaData<S, Boolean> with initial value and inherit flag both defaulting to false. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Color>> A function that returns the StyleableProperty<Color> that corresponds to this CssMetaData. function, final Color The initial value of the property. CSS may reset the property to this value. initialValue, final boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a CssMetaData<S, Color> with initial value, and inherit flag. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Color>> A function that returns the StyleableProperty<Color> that corresponds to this CssMetaData. function, final Color The initial value of the property. CSS may reset the property to this value. initialValue)Create a CssMetaData<S, Color> with initial value, and inherit flag defaulting to false. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Color>> A function that returns the StyleableProperty<Color> that corresponds to this CssMetaData. function)Create a CssMetaData<S, Color> with initial value of Color.BLACK, and inherit flag defaulting to false. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Duration>> A function that returns the StyleableProperty<Duration> that corresponds to this CssMetaData. function, final Duration The initial value of the property. CSS may reset the property to this value. initialValue, final boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a CssMetaData<S, Duration> with initial value, and inherit flag. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Duration>> A function that returns the StyleableProperty<Duration> that corresponds to this CssMetaData. function, final Duration The initial value of the property. CSS may reset the property to this value. initialValue)Create a CssMetaData<S, Duration> with initial value, and inherit flag defaulting to false. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Duration>> A function that returns the StyleableProperty<Duration> that corresponds to this CssMetaData. function)Create a CssMetaData<S, Duration> with initial value of Duration.BLACK, and inherit flag defaulting to false. |
| public final < The CssMetaData created with initial value and inherit flag E extends Effect> CssMetaData | Returns: a CssMetaData created with initial value, and inherit flagThe CSS property name. property, final Function<S, StyleableProperty<E>> A function that returns the StyleableProperty<Effect> that corresponds to this CssMetaData. function, final E The initial value of the property. CSS may reset the property to this value. initialValue, final boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a CssMetaData<S, Effect> with initial value, and inherit flag. |
| public final < The CssMetaData created with initial value and false inherit flag E extends Effect> CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<E>> A function that returns the StyleableProperty<Effect> that corresponds to this CssMetaData. function, final E The initial value of the property. CSS may reset the property to this value. initialValue)Create a CssMetaData<S, Effect> with initial value, and inherit flag defaulting to false. |
| public final < The CssMetaData created with null initial value and false inherit flag E extends Effect> CssMetaData | Returns: a CssMetaData created with null initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<E>> A function that returns the StyleableProperty<Effect> that corresponds to this CssMetaData. function)Create a CssMetaData<S, Effect> with initial value of null, and inherit flag defaulting to false. |
| public final < The CssMetaData created with initial value and inherit flag E extends Enum | Returns: a CssMetaData created with initial value, and inherit flagThe Enum class that is the type of the CssMetaData<E extends Enum<E>>. enumClass, final String The CSS property name. property, final Function<S, StyleableProperty<E>> A function that returns the StyleableProperty<Enum> that corresponds to this CssMetaData. function, final E The initial value of the property. CSS may reset the property to this value. initialValue, final boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a CssMetaData<S, Enum> with initial value, and inherit flag. |
| public final < The CssMetaData created with initial value and false inherit flag E extends Enum | Returns: a CssMetaData created with initial value, and false inherit flagThe Enum class that is the type of the CssMetaData<E extends Enum<E>>. enumClass, final String The CSS property name. property, final Function<S, StyleableProperty<E>> A function that returns the StyleableProperty<Enum> that corresponds to this CssMetaData. function, final E The initial value of the property. CSS may reset the property to this value. initialValue)Create a CssMetaData<S, Enum> with initial value, and inherit flag defaulting to false. |
| public final < The CssMetaData created with null initial value and false inherit flag E extends Enum | Returns: a CssMetaData created with null initial value, and false inherit flagThe Enum class that is the type of the CssMetaData<E extends Enum<E>>. enumClass, final String The CSS property name. property, final Function<S, StyleableProperty<E>> A function that returns the StyleableProperty<Enum> that corresponds to this CssMetaData. function)Create a CssMetaData<S, Enum> with initial value of null, and inherit flag defaulting to false. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Font>> A function that returns the StyleableProperty<Font> that corresponds to this CssMetaData. function, final Font The initial value of the property. CSS may reset the property to this value. initialValue, final boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a CssMetaData<S, Font> with initial value, and inherit flag. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and true inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Font>> A function that returns the StyleableProperty<Font> that corresponds to this CssMetaData. function, final Font The initial value of the property. CSS may reset the property to this value. initialValue)Create a CssMetaData<S, Font> with initial value, and inherit flag defaulting to true. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and true inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Font>> A function that returns the StyleableProperty<Font> that corresponds to this CssMetaData. function)Create a CssMetaData<S, Font> with initial value of |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Insets>> A function that returns the StyleableProperty<Insets> that corresponds to this CssMetaData. function, final Insets The initial value of the property. CSS may reset the property to this value. initialValue, final boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a CssMetaData<S, Insets> with initial value, and inherit flag. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Insets>> A function that returns the StyleableProperty<Insets> that corresponds to this CssMetaData. function, final Insets The initial value of the property. CSS may reset the property to this value. initialValue)Create a CssMetaData<S, Insets> with initial value, and inherit flag defaulting to false. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Insets>> A function that returns the StyleableProperty<Insets> that corresponds to this CssMetaData. function)Create a CssMetaData<S, Insets> with initial value of |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Paint>> A function that returns the StyleableProperty<Paint> that corresponds to this CssMetaData. function, final Paint The initial value of the property. CSS may reset the property to this value. initialValue, final boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a CssMetaData<S, Paint> with initial value, and inherit flag. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Paint>> A function that returns the StyleableProperty<Paint> that corresponds to this CssMetaData. function, final Paint The initial value of the property. CSS may reset the property to this value. initialValue)Create a CssMetaData<S, Paint> with initial value, and inherit flag defaulting to false. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Paint>> A function that returns the StyleableProperty<Paint> that corresponds to this CssMetaData. function)Create a CssMetaData<S, Paint> with initial value of Color.BLACK, and inherit flag defaulting to false. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Number>> A function that returns the StyleableProperty<Number> that corresponds to this CssMetaData. function, final Number The initial value of the property. CSS may reset the property to this value. initialValue, final boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a CssMetaData<S, Number> with initial value, and inherit flag. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Number>> A function that returns the StyleableProperty<Number> that corresponds to this CssMetaData. function, final Number The initial value of the property. CSS may reset the property to this value. initialValue)Create a CssMetaData<S, Number> with initial value, and inherit flag defaulting to false. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<Number>> A function that returns the StyleableProperty<Number> that corresponds to this CssMetaData. function)Create a CssMetaData<S, Number> with initial value of |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and inherit flagThe CSS property name. property, final Function<S, StyleableProperty<String>> A function that returns the StyleableProperty<String> that corresponds to this CssMetaData. function, final String The initial value of the property. CSS may reset the property to this value. initialValue, final boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a CssMetaData<S, String> with initial value, and inherit flag. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<String>> A function that returns the StyleableProperty<String> that corresponds to this CssMetaData. function, final String The initial value of the property. CSS may reset the property to this value. initialValue)Create a CssMetaData<S, String> with initial value, and inherit flag defaulting to false. |
| public final CssMetaData | Returns: a CssMetaData created with null initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<String>> A function that returns the StyleableProperty<String> that corresponds to this CssMetaData. function)Create a CssMetaData<S, String> with initial value of null, and inherit flag defaulting to false. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Boolean> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Boolean>> A function that returns the StyleableProperty<Boolean> that was created by this method call. function, boolean The initial value of the property. CSS may reset the property to this value. initialValue, boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a StyleableProperty<Boolean> with initial value and inherit flag. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial valueThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Boolean> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Boolean>> A function that returns the StyleableProperty<Boolean> that was created by this method call. function, boolean The initial value of the property. CSS may reset the property to this value. initialValue)Create a StyleableProperty<Boolean> with initial value. |
| public final StyleableProperty | Returns: a StyleableProperty created with default initialValue and inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Boolean> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Boolean>> A function that returns the StyleableProperty<Boolean> that was created by this method call. function)Create a StyleableProperty<Boolean>. |
| public final StyleableProperty | Returns: a StyleableProperty created using previously created CssMetaDataThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Boolean> propertyName, String The CSS property name cssProperty)Create a StyleableProperty<Boolean> using previously created CssMetaData for the given |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Color> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Color>> A function that returns the StyleableProperty<Color> that was created by this method call. function, Color The initial value of the property. CSS may reset the property to this value. initialValue, boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a StyleableProperty<Color> with initial value and inherit flag. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial valueThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Color> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Color>> A function that returns the StyleableProperty<Color> that was created by this method call. function, Color The initial value of the property. CSS may reset the property to this value. initialValue)Create a StyleableProperty<Color> with initial value. |
| public final StyleableProperty | Returns: a StyleableProperty created with default initial value and inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Color> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Color>> A function that returns the StyleableProperty<Color> that was created by this method call. function)Create a StyleableProperty<Color>. |
| public final StyleableProperty | Returns: a StyleableProperty created using previously created CssMetaDataThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Color> propertyName, String The CSS property name cssProperty)Create a StyleableProperty<Color> using previously created CssMetaData for the given |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Duration> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Duration>> A function that returns the StyleableProperty<Duration> that was created by this method call. function, Duration The initial value of the property. CSS may reset the property to this value. initialValue, boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a StyleableProperty<Duration> with initial value and inherit flag. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Duration> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Duration>> A function that returns the StyleableProperty<Duration> that was created by this method call. function, Duration The initial value of the property. CSS may reset the property to this value. initialValue)Create a StyleableProperty<Duration> with initial value. |
| public final StyleableProperty | Returns: a StyleableProperty created with default initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Duration> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Duration>> A function that returns the StyleableProperty<Duration> that was created by this method call. function)Create a StyleableProperty<Duration>. |
| public final StyleableProperty | Returns: a StyleableProperty created using previously created CssMetaDataThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Duration> propertyName, String The CSS property name cssProperty)Create a StyleableProperty<Duration> using previously created CssMetaData for the given |
| public final < The type of StyleableProperty E extends Effect> StyleableProperty | Returns: a StyleableProperty created with initial value and inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Effect> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<E>> A function that returns the StyleableProperty<Effect> that was created by this method call. function, E The initial value of the property. CSS may reset the property to this value. initialValue, boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a StyleableProperty<Effect> with initial value and inherit flag. |
| public final < The StyleableProperty created with initial value and false inherit flag E extends Effect> StyleableProperty | Returns: a StyleableProperty created with initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Effect> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<E>> A function that returns the StyleableProperty<Effect> that was created by this method call. function, E The initial value of the property. CSS may reset the property to this value. initialValue)Create a StyleableProperty<Effect> with initial value. |
| public final < The StyleableProperty created with null initial value and false inherit flag E extends Effect> StyleableProperty | Returns: a StyleableProperty created with null initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Effect> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<E>> A function that returns the StyleableProperty<Effect> that was created by this method call. function)Create a StyleableProperty<Effect>. |
| public final StyleableProperty | Returns: StyleableProperty created using previously created CssMetaData for the givencssPropertyThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Effect> propertyName, String The CSS property name cssProperty)Create a StyleableProperty<Effect> using previously created CssMetaData for the given |
| public final < The StyleableProperty created using previously created CssMetaData E extends Enum | Returns: a StyleableProperty created using previously created CssMetaDataThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<E extends Enum<E>> propertyName, String The CSS property name cssProperty, Class<E> The Enum class that is the type of the StyleableProperty<E extends Enum<E>>. enumClass)Create a StyleableProperty<E extends Enum<E>> using previously created CssMetaData for the given |
| public final < The StyleableProperty created with initial value and inherit flag E extends Enum | Returns: a StyleableProperty created with initial value and inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<E extends Enum<E>> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<E>> A function that returns the StyleableProperty<E extends Enum<E>> that was created by this method call. function, Class<E> The Enum class that is the type of the StyleableProperty<E extends Enum<E>>. enumClass, E The initial value of the property. CSS may reset the property to this value. initialValue, boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a StyleableProperty<E extends Enum<E>> with initial value and inherit flag. |
| public final < The StyleableProperty created with initial value and false inherit flag E extends Enum | Returns: a StyleableProperty created with initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<E extends Enum<E>> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<E>> A function that returns the StyleableProperty<E extends Enum<E>> that was created by this method call. function, Class<E> The Enum class that is the type of the StyleableProperty<E extends Enum<E>>. enumClass, E The initial value of the property. CSS may reset the property to this value. initialValue)Create a StyleableProperty<E extends Enum<E>> with initial value. |
| public final < The StyleableProperty created with null initial value and false inherit flag E extends Enum | Returns: a StyleableProperty created with null initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<E extends Enum<E>> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<E>> A function that returns the StyleableProperty<E extends Enum<E>> that was created by this method call. function, Class<E> The Enum class that is the type of the StyleableProperty<E extends Enum<E>>. enumClass)Create a StyleableProperty<E extends Enum<E>>. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Font> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Font>> A function that returns the StyleableProperty<Font> that was created by this method call. function, Font The initial value of the property. CSS may reset the property to this value. initialValue, boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a StyleableProperty<Font> with initial value and inherit flag. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and true inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Font> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Font>> A function that returns the StyleableProperty<Font> that was created by this method call. function, Font The initial value of the property. CSS may reset the property to this value. initialValue)Create a StyleableProperty<Font> with initial value. |
| public final StyleableProperty | Returns: a StyleableProperty created with default font initial value and true inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Font> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Font>> A function that returns the StyleableProperty<Font> that was created by this method call. function)Create a StyleableProperty<Font>. |
| public final StyleableProperty | Returns: a StyleableProperty created using previously created CssMetaDataThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Font> propertyName, String The CSS property name cssProperty)Create a StyleableProperty<Font> using previously created CssMetaData for the given |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Inset> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Insets>> A function that returns the StyleableProperty<Inset> that was created by this method call. function, Insets The initial value of the property. CSS may reset the property to this value. initialValue, boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a StyleableProperty<Inset> with initial value and inherit flag. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Inset> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Insets>> A function that returns the StyleableProperty<Inset> that was created by this method call. function, Insets The initial value of the property. CSS may reset the property to this value. initialValue)Create a StyleableProperty<Inset> with initial value. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Inset> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Insets>> A function that returns the StyleableProperty<Inset> that was created by this method call. function)Create a StyleableProperty<Inset>. |
| public final StyleableProperty | Returns: a StyleableProperty created using previously created CssMetaDataThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Insets> propertyName, String The CSS property name cssProperty)Create a StyleableProperty<Insets> using previously created CssMetaData for the given |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Number> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Number>> A function that returns the StyleableProperty<Number> that was created by this method call. function, Number The initial value of the property. CSS may reset the property to this value. initialValue, boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a StyleableProperty<Number> with initial value and inherit flag. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Number> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Number>> A function that returns the StyleableProperty<Number> that was created by this method call. function, Number The initial value of the property. CSS may reset the property to this value. initialValue)Create a StyleableProperty<Number> with initial value. |
| public final StyleableProperty | Returns: a StyleableProperty created with zero initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Number> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Number>> A function that returns the StyleableProperty<Number> that was created by this method call. function)Create a StyleableProperty<Number>. |
| public final StyleableProperty | Returns: a StyleableProperty created using previously created CssMetaDataThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Number> propertyName, String The CSS property name cssProperty)Create a StyleableProperty<Number> using previously created CssMetaData for the given |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Paint> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Paint>> A function that returns the StyleableProperty<Paint> that was created by this method call. function, Paint The initial value of the property. CSS may reset the property to this value. initialValue, boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a StyleableProperty<Paint> with initial value and inherit flag. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Paint> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Paint>> A function that returns the StyleableProperty<Paint> that was created by this method call. function, Paint The initial value of the property. CSS may reset the property to this value. initialValue)Create a StyleableProperty<Paint> with initial value. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Paint> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<Paint>> A function that returns the StyleableProperty<Paint> that was created by this method call. function)Create a StyleableProperty<Paint>. |
| public final StyleableProperty | Returns: a StyleableProperty created using previously created CssMetaDataThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<Paint> propertyName, String The CSS property name cssProperty)Create a StyleableProperty<Paint> using previously created CssMetaData for the given |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<String> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<String>> A function that returns the StyleableProperty<String> that was created by this method call. function, String The initial value of the property. CSS may reset the property to this value. initialValue, boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a StyleableProperty<String> with initial value and inherit flag. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<String> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<String>> A function that returns the StyleableProperty<String> that was created by this method call. function, String The initial value of the property. CSS may reset the property to this value. initialValue)Create a StyleableProperty<String> with initial value. |
| public final StyleableProperty | Returns: a StyleableProperty created with null initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<String> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<String>> A function that returns the StyleableProperty<String> that was created by this method call. function)Create a StyleableProperty<String>. |
| public final StyleableProperty | Returns: a StyleableProperty created using previously created CssMetaDataThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<String> propertyName, String The CSS property name cssProperty)Create a StyleableProperty<String> using previously created CssMetaData for the given |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<String> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<String>> A function that returns the StyleableProperty<String> that was created by this method call. function, String The initial value of the property. CSS may reset the property to this value. initialValue, boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a StyleableProperty<String> with initial value and inherit flag. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<String> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<String>> A function that returns the StyleableProperty<String> that was created by this method call. function, String The initial value of the property. CSS may reset the property to this value. initialValue)Create a StyleableProperty<String> with initial value. |
| public final StyleableProperty | Returns: a StyleableProperty created with initial value and false inherit flagThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<String> propertyName, String The CSS property name cssProperty, Function<S, StyleableProperty<String>> A function that returns the StyleableProperty<String> that was created by this method call. function)Create a StyleableProperty<String> with initial value. |
| public final StyleableProperty | Returns: a StyleableProperty created using previously created CssMetaDataThe styleable, String this reference of the returned property. This is also the property bean.The field name of the StyleableProperty<String> propertyName, String The CSS property name cssProperty)Create a StyleableProperty<String> using previously created CssMetaData for the given |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and inherit flagThe CSS property name. property, final Function<S, StyleableProperty<String>> A function that returns the StyleableProperty<String> that corresponds to this CssMetaData. function, final String The initial value of the property. CSS may reset the property to this value. initialValue, final boolean Whether or not the CSS style can be inherited by child nodes inherits)Create a CssMetaData<S, String> with initial value, and inherit flag. |
| public final CssMetaData | Returns: a CssMetaData created with initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<String>> A function that returns the StyleableProperty<String> that corresponds to this CssMetaData. function, final String The initial value of the property. CSS may reset the property to this value. initialValue)Create a CssMetaData<S, String> with initial value, and inherit flag defaulting to false. |
| public final CssMetaData | Returns: a CssMetaData created with null initial value, and false inherit flagThe CSS property name. property, final Function<S, StyleableProperty<String>> A function that returns the StyleableProperty<String> that corresponds to this CssMetaData. function)Create a CssMetaData<S, String> with initial value of null, and inherit flag defaulting to false. |
| public final List | Returns: the CssMetaData for the given StyleableGet the CssMetaData for the given Styleable. |
| private CssMetaData | |
| private CssMetaData | getCssMetaData(final Class<T> ofClass, String property, final Function<String, CssMetaData<S, ?>> createFunction)
|