public interface StyleResourceValue extends ResourceValue
ResourceValue.| Modifier and Type | Method and Description |
|---|---|
void |
addItem(StyleItemResourceValue item)
Adds a style item to this style.
|
java.util.Collection<StyleItemResourceValue> |
getDefinedItems()
Returns a list of all items defined in this Style.
|
StyleItemResourceValue |
getItem(ResourceNamespace namespace,
java.lang.String name)
Finds the item for the given qualified attr name in this style (if it's defined in this
style).
|
StyleItemResourceValue |
getItem(ResourceReference attr)
Finds the item for the given attr in this style (if it's defined in this style).
|
ResourceReference |
getParentStyle()
Returns a reference to the parent style, if it can be determined based on the explicit parent
reference in XML or by splitting the name of this
StyleResourceValue by dots. |
java.lang.String |
getParentStyleName()
Returns value of the
parent XML attribute of this style. |
void |
replaceWith(ResourceValue style)
Sets the value from another resource.
|
asReference, getLibraryName, getName, getNamespace, getNamespaceResolver, getRawXmlValue, getReference, getResourceType, getResourceUrl, getValue, isFramework, isUserDefined, setNamespaceLookup, setNamespaceResolver, setValue@Nullable java.lang.String getParentStyleName()
parent XML attribute of this style. Does not look at the name of
the style itself or dots in it.@Nullable ResourceReference getParentStyle()
StyleResourceValue by dots.@Nullable StyleItemResourceValue getItem(@NonNull ResourceNamespace namespace, @NonNull java.lang.String name)
@Nullable StyleItemResourceValue getItem(@NonNull ResourceReference attr)
void addItem(@NonNull
StyleItemResourceValue item)
item - the style item to addvoid replaceWith(@NonNull
ResourceValue style)
ResourceValuereplaceWith in interface ResourceValuestyle - the resource value@NonNull java.util.Collection<StyleItemResourceValue> getDefinedItems()