org.apache.wink.server.utils
Class RegistrationUtils

java.lang.Object
  extended by org.apache.wink.server.utils.RegistrationUtils

public class RegistrationUtils
extends Object


Nested Class Summary
static class RegistrationUtils.InnerApplication
           
 
Constructor Summary
RegistrationUtils()
           
 
Method Summary
static void registerApplication(javax.ws.rs.core.Application application, javax.servlet.ServletContext servletContext)
          Registers resources and providers provided by the Application.
static void registerApplication(javax.ws.rs.core.Application application, javax.servlet.ServletContext servletContext, String requestProcessorAttribute)
          Registers resources and providers provided by the Application.
static void registerClasses(javax.servlet.ServletContext servletContext, Class<?>... classes)
           
static void registerClasses(javax.servlet.ServletContext servletContext, String requestProcessorAttribute, Class<?>... classes)
           
static void registerInstances(javax.servlet.ServletContext servletContext, Object... instances)
           
static void registerInstances(javax.servlet.ServletContext servletContext, String requestProcessorAttribute, Object... instances)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RegistrationUtils

public RegistrationUtils()
Method Detail

registerApplication

public static void registerApplication(javax.ws.rs.core.Application application,
                                       javax.servlet.ServletContext servletContext)
Registers resources and providers provided by the Application. The methods adds new providers and resources and DOES NOT removes the already registered.

Parameters:
application - - application to register
servletContext - - current servlet context

registerClasses

public static void registerClasses(javax.servlet.ServletContext servletContext,
                                   Class<?>... classes)

registerInstances

public static void registerInstances(javax.servlet.ServletContext servletContext,
                                     Object... instances)

registerInstances

public static void registerInstances(javax.servlet.ServletContext servletContext,
                                     String requestProcessorAttribute,
                                     Object... instances)

registerClasses

public static void registerClasses(javax.servlet.ServletContext servletContext,
                                   String requestProcessorAttribute,
                                   Class<?>... classes)

registerApplication

public static void registerApplication(javax.ws.rs.core.Application application,
                                       javax.servlet.ServletContext servletContext,
                                       String requestProcessorAttribute)
Registers resources and providers provided by the Application. The methods adds new providers and resources and DOES NOT removes the already registered.

Parameters:
application - - application to register
servletContext - - current servlet context
requestProcessorAttribute - - attribute on which the request processor is stored. It's useful, when there are multiple rest servlets in the system and each one has a request processor.


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