|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface BasicNode
Represents a "basic" node in the JCR, typically an unstructured node that may or may not exist in a CQ page hierarchy. Examples of non-page descendant nodes that could be considered basic nodes include design nodes and arbitrary unstructured nodes that do not require inheritance capabilities.
Many methods return an Optional type where a null instance would otherwise be returned (e.g. when a descendant node is requested for a path that does not exist in the repository).
| Method Summary | |
|---|---|
String |
getId()
Get the unique ID for this resource based on the path. |
int |
getIndex()
Get the index of this resource in relation to sibling nodes. |
int |
getIndex(String resourceType)
Get the index of this node in relation to sibling nodes, ignoring resource types that do not match the specified value. |
Optional<Node> |
getNode()
Get the JCR node for this instance. |
String |
getPath()
Shortcut for getting the current resource path. |
List<Property> |
getProperties(Predicate<Property> predicate)
Get a list of properties that apply for the given predicate. |
Resource |
getResource()
Get the underlying resource for this instance. |
| Methods inherited from interface com.citytechinc.aem.bedrock.api.Linkable |
|---|
getHref, getHref, getLink, getLink, getLinkBuilder, getLinkBuilder |
| Methods inherited from interface com.citytechinc.aem.bedrock.api.ImageSource |
|---|
getImageSource, getImageSource, getImageSource, getImageSource, isHasImage, isHasImage |
| Methods inherited from interface com.citytechinc.aem.bedrock.api.Accessible |
|---|
asMap, get, get, getAsHref, getAsHref, getAsHref, getAsLink, getAsLink, getAsLink, getAsList, getAsPage, getAsType, getImageReference, getImageReference, getImageRendition, getImageRendition |
| Method Detail |
|---|
String getId()
int getIndex()
int getIndex(String resourceType)
resourceType - sling:resourceType to filter on
Optional<Node> getNode()
Optional if the underlying resource
for this instance is synthetic or non-existent.
Optional node for this resourceString getPath()
List<Property> getProperties(Predicate<Property> predicate)
predicate - predicate to apply
Resource getResource()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||