org.apache.sling.superimposing.impl

## Class SuperimposingResource

- java.lang.Object
- - org.apache.sling.api.adapter.SlingAdaptable
  - - org.apache.sling.api.resource.AbstractResource
    - - org.apache.sling.superimposing.impl.SuperimposingResource

All Implemented Interfaces:
  org.apache.sling.api.adapter.Adaptable, org.apache.sling.api.resource.Resource

    public class SuperimposingResource
    extends org.apache.sling.api.resource.AbstractResource
    implements org.apache.sling.api.resource.Resource

`SuperimposingResource` is provided by `SuperimposingResourceProviderImpl` instances. It delegates to an existing underlying resource but overrides the getPath() method to point to the superimposed path.

### Field Summary

### Fields inherited from interface org.apache.sling.api.resource.Resource

`RESOURCE_TYPE_NON_EXISTING`

### Constructor Summary

Constructors
Constructor and Description
`SuperimposingResource(org.apache.sling.api.resource.Resource mappedResource, String path)`

### Method Summary

Methods
`<AdapterType> AdapterType` `adaptTo(Class<AdapterType> type)`
`String` `getPath()`
`org.apache.sling.api.resource.ResourceMetadata` `getResourceMetadata()`
`org.apache.sling.api.resource.ResourceResolver` `getResourceResolver()`
`String` `getResourceSuperType()`
`String` `getResourceType()`
`String` `toString()`

### Methods inherited from class org.apache.sling.api.resource.AbstractResource

`getChild, getName, getParent, isResourceType, listChildren`

### Methods inherited from class org.apache.sling.api.adapter.SlingAdaptable

`setAdapterManager, unsetAdapterManager`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Methods inherited from interface org.apache.sling.api.resource.Resource

`getChild, getName, getParent, isResourceType, listChildren`

### Constructor Detail

#### SuperimposingResource

    public SuperimposingResource(org.apache.sling.api.resource.Resource mappedResource,
                         String path)

Parameters:
  `mappedResource` - Mapped resource
  `path` - Path

### Method Detail

#### getPath

    public String getPath()

Specified by:
  `getPath` in interface `org.apache.sling.api.resource.Resource`

#### getResourceType

    public String getResourceType()

Specified by:
  `getResourceType` in interface `org.apache.sling.api.resource.Resource`

#### getResourceSuperType

    public String getResourceSuperType()

Specified by:
  `getResourceSuperType` in interface `org.apache.sling.api.resource.Resource`

#### getResourceMetadata

    public org.apache.sling.api.resource.ResourceMetadata getResourceMetadata()

Specified by:
  `getResourceMetadata` in interface `org.apache.sling.api.resource.Resource`

#### getResourceResolver

    public org.apache.sling.api.resource.ResourceResolver getResourceResolver()

Specified by:
  `getResourceResolver` in interface `org.apache.sling.api.resource.Resource`

#### adaptTo

    public <AdapterType> AdapterType adaptTo(Class<AdapterType> type)

Specified by:
  `adaptTo` in interface `org.apache.sling.api.adapter.Adaptable`
Overrides:
  `adaptTo` in class `org.apache.sling.api.adapter.SlingAdaptable`

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`