Class ClientlibCategoryServlet

  • All Implemented Interfaces:
    Serializable, javax.servlet.Servlet, javax.servlet.ServletConfig

    public class ClientlibCategoryServlet
    extends AbstractClientlibServlet
    Serves the clientlibs of a whole category with all embedded stuff. The path /bin/cpm/clientlib.{type}/{hash}/{categoryname}.{type} needs the type as extension and the hash, category and type as suffix.
    See Also:
    Serialized Form
    • Constructor Detail

      • ClientlibCategoryServlet

        public ClientlibCategoryServlet()
    • Method Detail

      • makePath

        public static String makePath​(String category,
                                      Clientlib.Type type,
                                      boolean minified,
                                      String hash)
        Creates an path that is rendered by this servlet containing the given parameters.
      • doGet

        protected void doGet​(@NotNull
                             @NotNull org.apache.sling.api.SlingHttpServletRequest request,
                             @NotNull
                             @NotNull org.apache.sling.api.SlingHttpServletResponse response)
                      throws javax.servlet.ServletException,
                             IOException
        Overrides:
        doGet in class org.apache.sling.api.servlets.SlingSafeMethodsServlet
        Throws:
        javax.servlet.ServletException
        IOException
      • doHead

        protected void doHead​(@NotNull
                              @NotNull org.apache.sling.api.SlingHttpServletRequest request,
                              @NotNull
                              @NotNull org.apache.sling.api.SlingHttpServletResponse response)
                       throws javax.servlet.ServletException,
                              IOException
        Overrides:
        doHead in class org.apache.sling.api.servlets.SlingSafeMethodsServlet
        Throws:
        javax.servlet.ServletException
        IOException
      • parseCategoryAndHashFromSuffix

        public static org.apache.commons.lang3.tuple.Pair<String,​String> parseCategoryAndHashFromSuffix​(String suffix)