SLING-8170 - Allow Sling servlets to declare a resource super type

diff --git a/pom.xml b/pom.xml
index 959c104..ba27645 100644
--- a/pom.xml
+++ b/pom.xml
@@ -58,7 +58,7 @@
             <groupId>org.apache.sling</groupId>
             <artifactId>org.apache.sling.api</artifactId>
             <!-- https://issues.apache.org/jira/browse/SLING-6249, only for link in javadoc -->
-            <version>2.16.0</version>
+            <version>2.18.5-SNAPSHOT</version>
             <scope>provided</scope>
         </dependency>
         <dependency>
diff --git a/src/main/java/org/apache/sling/servlets/annotations/SlingServletResourceTypes.java b/src/main/java/org/apache/sling/servlets/annotations/SlingServletResourceTypes.java
index 053d66e..a69f07f 100644
--- a/src/main/java/org/apache/sling/servlets/annotations/SlingServletResourceTypes.java
+++ b/src/main/java/org/apache/sling/servlets/annotations/SlingServletResourceTypes.java
@@ -22,7 +22,7 @@
  * Component Property Type (as defined by OSGi DS 1.4) for Sling Servlets.
  * Takes care of writing the relevant service properties as being used by the Sling Servlet Resolver ({@link ServletResolverConstants})
  * to register the annotated servlet component as Sling servlet for a specific resource type.
- * 
+ *
  * @see <a href="https://sling.apache.org/documentation/the-sling-engine/servlets.html">Sling Servlets</a>
  * @see ServletResolverConstants
  * @see <a href="https://github.com/apache/felix/blob/trunk/tools/org.apache.felix.scr.annotations/src/main/java/org/apache/felix/scr/annotations/sling/SlingServlet.java">Felix SCR annotation</a>
@@ -43,18 +43,29 @@
      * @return the resource type(s)
      */
     String[] resourceTypes();
-    
+
+    /**
+     * The resource super type from which the servlet inherits (value is "sling.servlet.resourceSuperType").
+     *
+     * <p>In order for this property to be taken into consideration, the {@code org.apache.sling.servlets.resolver} bundle needs to be
+     * deployed on the system, version 2.5.0 or above.
+     *
+     * @return the resource super type
+     * @see ServletResolverConstants#SLING_SERVLET_RESOURCE_SUPER_TYPE
+     */
+    String resourceSuperType();
+
     /**
      * One ore more request URL selectors supported by the servlet. The
      * selectors must be configured in the order as they would be specified in the URL that
      * is as a list of dot-separated strings such as <em>print.a4</em>.
-     * In case this is not empty the first selector(s) (i.e. the one on the left in the URL) must match, 
+     * In case this is not empty the first selector(s) (i.e. the one on the left in the URL) must match,
      * otherwise the servlet is not executed. After that may follow arbitrarily many non-registered selectors.
      * @return the selector(s)
      * @see ServletResolverConstants#SLING_SERVLET_SELECTORS
      */
     String[] selectors() default {};
-    
+
     /**
      * The request URL extensions supported by the servlet.
      * <p>
@@ -63,9 +74,9 @@
      * @see ServletResolverConstants#SLING_SERVLET_EXTENSIONS
      */
     String[] extensions() default {};
-    
+
     /**
-     * The request methods supported by the servlet. The value may be one of the HTTP 
+     * The request methods supported by the servlet. The value may be one of the HTTP
      * methods or "*" for all methods.
      * <p>
      * If this is not set (i.e. empty array) it is assumed to be {@code GET} and {@code HEAD}.