ColorBuilders.ColorProp
@RequiresSchemaVersion(major = 1, minor = 0)
public final class ColorBuilders.ColorProp
A property defining a color.
Summary
Nested types |
|---|
public final class ColorBuilders.ColorProp.BuilderBuilder for |
Public methods |
|
|---|---|
@ColorInt int |
getArgb()Gets the static color value, in ARGB format. |
@Nullable DynamicBuilders.DynamicColor |
Gets the dynamic value. |
@NonNull String |
toString() |
Public methods
getArgb
public @ColorInt int getArgb()
Gets the static color value, in ARGB format. If a dynamic value is also set and the renderer supports dynamic values for the corresponding field, this static value will be ignored. If the static value is not specified, zero (equivalent to TRANSPARENT) will be used instead.
getDynamicValue
public @Nullable DynamicBuilders.DynamicColor getDynamicValue()
Gets the dynamic value. Note that when setting this value, the static value is still required to be set to support older renderers that only read the static value. If
dynamicValue has an invalid result, the provided static value will be used instead.