Class SpringRESTController

  extended by
All Implemented Interfaces:
Controller, org.springframework.beans.factory.Aware, org.springframework.context.ApplicationContextAware

public class SpringRESTController
extends Object
implements Controller, org.springframework.context.ApplicationContextAware

This controller is responsible for the execution of instances of REST controller beans. Note that each controller implementation must be available as Spring bean. For that purpose you can use the RESTController annotation and load all beans from a particular package automatically. See for details.

Constructor Summary
Method Summary
 void execute(OutputStream outputStream)
 CacheKey getCacheKey()
          This method returns the cache key that might be available after the setup phase.
 void setAnnotationCollector(AnnotationCollector annotationCollector)
 void setApplicationContext(org.springframework.context.ApplicationContext applicationContext)
 void setMethodDelegator(MethodDelegator methodDelegator)
 void setup(String controllerName, Map<String,Object> inputParameters, Map<String,? extends Object> configuration)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


public SpringRESTController()
Method Detail


public CacheKey getCacheKey()
Description copied from interface: Controller
This method returns the cache key that might be available after the setup phase.

Specified by:
getCacheKey in interface Controller
A CacheKey for the controller or null if no cache key can be calculated.


public void setup(String controllerName,
                  Map<String,Object> inputParameters,
                  Map<String,? extends Object> configuration)

Specified by:
setup in interface Controller
UnknownControllerException - if a controller is requested that is not registered as Spring bean.
NonPrototypeControllerException - if the requested controller is not configured to run in the prototype scope.
IllegalFieldAnnotationException - if the requested controller contains dependency injection fields that cannot be satisfied.
See Also:
Controller.setup(java.lang.String, java.util.Map, java.util.Map)


public void execute(OutputStream outputStream)
Specified by:
execute in interface Controller


public void setAnnotationCollector(AnnotationCollector annotationCollector)


public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext)

Specified by:
setApplicationContext in interface org.springframework.context.ApplicationContextAware
See Also:


public void setMethodDelegator(MethodDelegator methodDelegator)

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