Package com.day.cq.wcm.api.designer
Interface Style
- All Known Implementing Classes:
ContentPolicyStyle
A style contains properties that reflect the design aspect of a cell.
-
Nested Class Summary
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescription<T> TReturn named value converted to type T ornullif not existing.<T> Treturn named value converted to the type T of the default value or the default value if the named value does not existgetCell()Returns the cell of this stylegetDefiningPath(String name) Returns the cell path that defines the style property with the given name.getDefiningResource(String name) Returns the resource that defines the style property with the given name.Returns the design this style is defined in.getPath()Returns the path to this cell resourcegetSubStyle(String relPath) Returns a sub style for the give one, by virtually extending the cell stack.Methods inherited from interface java.util.Map
clear, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, equals, forEach, get, getOrDefault, hashCode, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
-
Method Details
-
getDesign
Design getDesign()Returns the design this style is defined in.- Returns:
- the design.
-
getPath
String getPath()Returns the path to this cell resource- Returns:
- the path
-
getCell
Cell getCell()Returns the cell of this style- Returns:
- the cell
-
get
Return named value converted to type T ornullif not existing. Please note that this also supports aResourceclass as type in order to retrieve a style resource (e.g. image) -
get
return named value converted to the type T of the default value or the default value if the named value does not exist -
getDefiningResource
Returns the resource that defines the style property with the given name.- Parameters:
name- name of the style property- Returns:
- resource or
null
-
getDefiningPath
Returns the cell path that defines the style property with the given name.- Parameters:
name- name of the style property- Returns:
- path or
null
-
getSubStyle
Returns a sub style for the give one, by virtually extending the cell stack.- Parameters:
relPath- relative path of the sub style.- Returns:
- the new style
-