public class GuideValueMapResource extends ValueMapResource
RESOURCE_TYPE_NON_EXISTING
Constructor and Description |
---|
GuideValueMapResource(ResourceResolver resourceResolver,
ResourceMetadata rm,
java.lang.String resourceType,
ValueMap vm,
java.util.Collection<Resource> children,
Resource parentResource)
Creates a
ValueMapResource based on provided parameters, with the ability to define the children |
GuideValueMapResource(ResourceResolver resourceResolver,
ResourceMetadata rm,
java.lang.String resourceType,
ValueMap vm,
Resource parentResource)
Creates a
GuideValueMapResource based on provided parameters |
GuideValueMapResource(ResourceResolver resourceResolver,
java.lang.String path,
java.lang.String resourceType,
ValueMap vm,
java.util.Collection<Resource> children,
Resource parentResource)
Creates a
GuideValueMapResource based on provided parameters, with the ability to define the children and its parent. |
GuideValueMapResource(ResourceResolver resourceResolver,
java.lang.String path,
java.lang.String resourceType,
ValueMap vm,
Resource parentResource)
Creates a
GuideValueMapResource based on provided parameters |
Modifier and Type | Method and Description |
---|---|
<Type> Type |
adaptTo(java.lang.Class<Type> type)
Calls into the registered
AdapterManager to adapt this object to
the desired type . |
Resource |
getChild(java.lang.String relPath)
Returns the indicated child of this resource.
|
Resource |
getParent()
Returns the parent resource of this resource.
|
getChildren, hasChildren, listChildren
getPath, getResourceMetadata, getResourceResolver, getResourceSuperType, getResourceType, toString
getName, getValueMap, isResourceType
setAdapterManager, unsetAdapterManager
public GuideValueMapResource(ResourceResolver resourceResolver, java.lang.String path, java.lang.String resourceType, ValueMap vm, Resource parentResource)
GuideValueMapResource
based on provided parametersresourceResolver
- The resource resolverpath
- The resource pathresourceType
- The resource typevm
- The properties of the resourceparentResource
- parent resource of this synthetic resource.public GuideValueMapResource(ResourceResolver resourceResolver, java.lang.String path, java.lang.String resourceType, ValueMap vm, java.util.Collection<Resource> children, Resource parentResource)
GuideValueMapResource
based on provided parameters, with the ability to define the children and its parent.resourceResolver
- The resource resolverpath
- The resource pathresourceType
- The resource typevm
- The properties of the resourcechildren
- The children of the resourceparentResource
- parent resource of this synthetic resource.public GuideValueMapResource(ResourceResolver resourceResolver, ResourceMetadata rm, java.lang.String resourceType, ValueMap vm, Resource parentResource)
GuideValueMapResource
based on provided parametersresourceResolver
- The resource resolverrm
- The resource meta dataresourceType
- The resource typevm
- The properties of the resourceparentResource
- parent resource of this synthetic resource.public GuideValueMapResource(ResourceResolver resourceResolver, ResourceMetadata rm, java.lang.String resourceType, ValueMap vm, java.util.Collection<Resource> children, Resource parentResource)
ValueMapResource
based on provided parameters, with the ability to define the childrenresourceResolver
- The resource resolverrm
- The resource meta dataresourceType
- The resource typevm
- The properties of the resourcechildren
- The children of the resourceparentResource
- parent resource of this synthetic resource.public <Type> Type adaptTo(java.lang.Class<Type> type)
SlingAdaptable
AdapterManager
to adapt this object to
the desired type
.
This method implements a cache of adapters to improve performance. That is repeated calls to this method with the same class will result in the same object to be returned.
adaptTo
in interface Adaptable
adaptTo
in class ValueMapResource
Type
- The generic type to which this resource is adapted
totype
- The Class object of the target type, such as
javax.jcr.Node.class
or
java.io.File.class
null
if the resource cannot
adapt to the requested typepublic Resource getChild(java.lang.String relPath)
AbstractResource
This method is implemented calling the
ResourceResolver.getResource(Resource, String)
method. As such
the relPath
argument may even be an absolute path or a path
containing relative path segments .
(current resource) and
..
(parent resource).
Implementations should not generally overwrite this method without calling this base class implementation.
getChild
in interface Resource
getChild
in class ValueMapResource
relPath
- relative path to the child resourcenull
Resource.getChild(String)
public Resource getParent()
AbstractResource
This method is implemented calling the ResourceResolver.getParent(Resource)
method.
getParent
in interface Resource
getParent
in class AbstractResource
null
.ResourceResolver.getParent(Resource)
Copyright © 2010 - 2020 Adobe. All Rights Reserved