Class NodeTypesServlet

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

    public class NodeTypesServlet
    extends org.apache.sling.api.servlets.SlingSafeMethodsServlet
    implements RestrictedService
    A servlet that exports the nodetypes in the format used in nodetypes.cnd. E.g. http://localhost:9090/bin/cpm/nodes/debug/nodetypes?nameregex=cpp%3A.%2A
    See Also:
    Serialized Form
    • Constructor Detail

      • NodeTypesServlet

        public NodeTypesServlet()
    • Method Detail

      • 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
      • writeNodetypes

        protected void writeNodetypes​(javax.jcr.Session session,
                                      PrintWriter writer,
                                      Pattern nodetypeSelector)
                               throws javax.jcr.RepositoryException,
                                      IOException
        Throws:
        javax.jcr.RepositoryException
        IOException