org.apache.cocoon.rest.jaxrs.container
Class CocoonJAXRSServlet

java.lang.Object
  extended by javax.servlet.GenericServlet
      extended by javax.servlet.http.HttpServlet
          extended by com.sun.jersey.spi.container.servlet.ServletContainer
              extended by org.apache.cocoon.rest.jaxrs.container.CocoonJAXRSServlet
All Implemented Interfaces:
Serializable, javax.servlet.Filter, javax.servlet.Servlet, javax.servlet.ServletConfig

public class CocoonJAXRSServlet
extends com.sun.jersey.spi.container.servlet.ServletContainer

A Servlet that can be used in the Cocoon Servlet-Service framework. Extending the ServletContainer provided by Jersey it registers all passed REST resources ( #setRestResources(Map) and setRestResourcesList(List).

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class com.sun.jersey.spi.container.servlet.ServletContainer
com.sun.jersey.spi.container.servlet.ServletContainer.ContextInjectableProvider<T>
 
Field Summary
 
Fields inherited from class com.sun.jersey.spi.container.servlet.ServletContainer
APPLICATION_CONFIG_CLASS, FEATURE_FILTER_FORWARD_ON_404, GLASSFISH_DEFAULT_ERROR_PAGE_RESPONSE, JSP_TEMPLATES_BASE_PATH, PROPERTY_FILTER_CONTEXT_PATH, PROPERTY_WEB_PAGE_CONTENT_REGEX, RESOURCE_CONFIG_CLASS
 
Constructor Summary
CocoonJAXRSServlet()
           
 
Method Summary
protected  com.sun.jersey.api.core.ResourceConfig getDefaultResourceConfig(Map<String,Object> props, javax.servlet.ServletConfig servletConfig)
           
protected  void initiate(com.sun.jersey.api.core.ResourceConfig rc, com.sun.jersey.spi.container.WebApplication wa)
           
 void service(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
           
 void setRestResourcesList(List<Object> restResourcesList)
           
 void setRestResourcesMap(Map<Object,Object> restResourcesMap)
           
 
Methods inherited from class com.sun.jersey.spi.container.servlet.ServletContainer
configure, configure, configure, create, destroy, doFilter, doFilter, getDefaultResourceConfig, getServletContext, getStaticContentPattern, getWebConfig, init, init, init, load, reload, service
 
Methods inherited from class javax.servlet.http.HttpServlet
doDelete, doGet, doHead, doOptions, doPost, doPut, doTrace, getLastModified, service
 
Methods inherited from class javax.servlet.GenericServlet
getInitParameter, getInitParameterNames, getServletConfig, getServletInfo, getServletName, init, log, log
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CocoonJAXRSServlet

public CocoonJAXRSServlet()
Method Detail

service

public void service(javax.servlet.http.HttpServletRequest request,
                    javax.servlet.http.HttpServletResponse response)
             throws javax.servlet.ServletException,
                    IOException
Overrides:
service in class com.sun.jersey.spi.container.servlet.ServletContainer
Throws:
javax.servlet.ServletException
IOException

setRestResourcesMap

public void setRestResourcesMap(Map<Object,Object> restResourcesMap)

setRestResourcesList

public void setRestResourcesList(List<Object> restResourcesList)

getDefaultResourceConfig

protected com.sun.jersey.api.core.ResourceConfig getDefaultResourceConfig(Map<String,Object> props,
                                                                          javax.servlet.ServletConfig servletConfig)
                                                                   throws javax.servlet.ServletException
Overrides:
getDefaultResourceConfig in class com.sun.jersey.spi.container.servlet.ServletContainer
Throws:
javax.servlet.ServletException

initiate

protected void initiate(com.sun.jersey.api.core.ResourceConfig rc,
                        com.sun.jersey.spi.container.WebApplication wa)
Overrides:
initiate in class com.sun.jersey.spi.container.servlet.ServletContainer


Copyright © 2008-2012 The Apache Software Foundation. All Rights Reserved.