Package org.apache.sling.servlets.resolver.internal.resource

# Class ServletResource

java.lang.Object
org.apache.sling.api.adapter.SlingAdaptable
org.apache.sling.api.resource.AbstractResource
org.apache.sling.servlets.resolver.internal.resource.ServletResource

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

public class ServletResource extends org.apache.sling.api.resource.AbstractResource

## Field Summary

Fields
Modifier and Type
Field
Description
`static final String`
`DEFAULT_RESOURCE_SUPER_TYPE`

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

`RESOURCE_TYPE_NON_EXISTING`

## Constructor Summary

Constructors
Constructor
Description
`ServletResource(org.apache.sling.api.resource.ResourceResolver resourceResolver, jakarta.servlet.Servlet servlet, String path)`

## Method Summary

Modifier and Type
Method
Description
`<T> T`
`adaptTo(Class<T> 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, getChildren, getName, getParent, getValueMap, hasChildren, 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`

## Field Details

### DEFAULT_RESOURCE_SUPER_TYPE

public static final String DEFAULT_RESOURCE_SUPER_TYPE

See Also:
  - Constant Field Values

## Constructor Details

### ServletResource

public ServletResource(org.apache.sling.api.resource.ResourceResolver resourceResolver, jakarta.servlet.Servlet servlet, String path)

## Method Details

### getResourceMetadata

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

### getResourceResolver

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

### getResourceType

public String getResourceType()

### getResourceSuperType

public String getResourceSuperType()

### getPath

public String getPath()

### adaptTo

public <T> T adaptTo(Class<T> 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`