Module org.jhotdraw8.svg
Package org.jhotdraw8.svg.key
Class SvgDefaultablePaintStyleableKey<T extends Paintable>
java.lang.Object
org.jhotdraw8.fxcollection.typesafekey.AbstractKey<@NonNull org.jhotdraw8.svg.css.SvgDefaultablePaint<T>>
org.jhotdraw8.draw.key.AbstractStyleableKey<@NonNull org.jhotdraw8.svg.css.SvgDefaultablePaint<T>>
org.jhotdraw8.svg.key.SvgDefaultablePaintStyleableKey<T>
- All Implemented Interfaces:
Serializable,org.jhotdraw8.fxbase.styleable.ReadOnlyStyleableMapAccessor<@NonNull org.jhotdraw8.svg.css.SvgDefaultablePaint<T>>,org.jhotdraw8.fxbase.styleable.WritableStyleableMapAccessor<@NonNull org.jhotdraw8.svg.css.SvgDefaultablePaint<T>>,org.jhotdraw8.fxcollection.typesafekey.Key<@NonNull org.jhotdraw8.svg.css.SvgDefaultablePaint<T>>,org.jhotdraw8.fxcollection.typesafekey.MapAccessor<@NonNull org.jhotdraw8.svg.css.SvgDefaultablePaint<T>>,org.jhotdraw8.fxcollection.typesafekey.NonNullMapAccessor<org.jhotdraw8.svg.css.SvgDefaultablePaint<T>>,SvgDefaultablePaintStyleableMapAccessor<T>
public class SvgDefaultablePaintStyleableKey<T extends Paintable>
extends AbstractStyleableKey<@NonNull org.jhotdraw8.svg.css.SvgDefaultablePaint<T>>
implements org.jhotdraw8.fxbase.styleable.WritableStyleableMapAccessor<@NonNull org.jhotdraw8.svg.css.SvgDefaultablePaint<T>>, SvgDefaultablePaintStyleableMapAccessor<T>
TListStyleableFigureKey.
- Author:
- Werner Randelshofer
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionSvgDefaultablePaintStyleableKey(@NonNull String name, @NonNull Type type, @NonNull org.jhotdraw8.css.converter.CssConverter<T> converter, @NonNull org.jhotdraw8.svg.css.SvgDefaultablePaint<T> initialDefaultingValue, @Nullable T initialValue) Creates a new instance with the specified name, mask and default value. -
Method Summary
Modifier and TypeMethodDescriptionReturns the initial value of the attribute.Methods inherited from class org.jhotdraw8.draw.key.AbstractStyleableKey
getCssName, getCssNamespaceMethods inherited from class org.jhotdraw8.fxcollection.typesafekey.AbstractKey
getDefaultValue, getName, getValueType, isNullable, isTransient, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.jhotdraw8.fxcollection.typesafekey.Key
cast, containsKey, get, get, getValue, getValueProperty, isAssignable, isDefault, propertyAt, put, put, putValue, readOnlyPropertyAt, remove, remove, valueAtMethods inherited from interface org.jhotdraw8.fxcollection.typesafekey.MapAccessor
getDefaultValue, getName, getRawValueType, getValueType, isTransient, setMethods inherited from interface org.jhotdraw8.fxcollection.typesafekey.NonNullMapAccessor
getDefaultValueNonNull, getNonNull, getNonNull, putNonNullMethods inherited from interface org.jhotdraw8.fxbase.styleable.ReadOnlyStyleableMapAccessor
getCssName, getCssNamespaceMethods inherited from interface org.jhotdraw8.fxbase.styleable.WritableStyleableMapAccessor
getExamples
-
Constructor Details
-
SvgDefaultablePaintStyleableKey
public SvgDefaultablePaintStyleableKey(@NonNull String name, @NonNull Type type, @NonNull org.jhotdraw8.css.converter.CssConverter<T> converter, @NonNull org.jhotdraw8.svg.css.SvgDefaultablePaint<T> initialDefaultingValue, @Nullable T initialValue) Creates a new instance with the specified name, mask and default value.- Parameters:
name- The name of the key.type- The full typeconverter- String converter for a list elementinitialDefaultingValue- The default value.
-
-
Method Details
-
getCssConverter
-
getInitialValue
Returns the initial value of the attribute.We use the definition from CSS initial value:
"Each property has an initial value, defined in the property's definition table. If the property is not an inherited property, and the cascade does not result in a value, then the specified value of the property is its initial value."
We intentionally do not use the definition from SVG initial value:
"The initial value of an attribute or property is the value used when that attribute or property is not specified, or when it has an invalid value."References:
- Specified by:
getInitialValuein interfaceSvgDefaultablePaintStyleableMapAccessor<T extends Paintable>- Returns:
- the initial value.
-