public class SpringModuleDef extends java.lang.Object implements ModuleDef
ApplicationContext
into a set of service definitions,
compatible with
Tapestry 5 IoC, for the beans defined in the context, as well as the context itself.Constructor and Description |
---|
SpringModuleDef(javax.servlet.ServletContext servletContext) |
Modifier and Type | Method and Description |
---|---|
java.lang.Class |
getBuilderClass()
Returns the class that will be instantiated.
|
java.util.Set<ContributionDef> |
getContributionDefs()
Returns a contribution, "SpringBean", to the MasterObjectProvider service.
|
java.util.Set<DecoratorDef> |
getDecoratorDefs()
Returns an empty set.
|
java.lang.String |
getLoggerName()
Returns the name used to create a
Logger instance. |
ServiceDef |
getServiceDef(java.lang.String serviceId)
Returns a service definition via the service's id.
|
java.util.Set<java.lang.String> |
getServiceIds()
Returns the ids of the services built/provided by the module.
|
protected org.springframework.context.ApplicationContext |
locateApplicationContext(javax.servlet.ServletContext servletContext)
Invoked to obtain the Spring ApplicationContext, presumably stored in the ServletContext.
|
public SpringModuleDef(javax.servlet.ServletContext servletContext)
protected org.springframework.context.ApplicationContext locateApplicationContext(javax.servlet.ServletContext servletContext)
servletContext
- used to locate the ApplicationContextjava.lang.RuntimeException
- if the ApplicationContext could not be located or is otherwise invalidpublic java.lang.Class getBuilderClass()
ModuleDef
getBuilderClass
in interface ModuleDef
public java.util.Set<ContributionDef> getContributionDefs()
getContributionDefs
in interface ModuleDef
public java.util.Set<DecoratorDef> getDecoratorDefs()
getDecoratorDefs
in interface ModuleDef
public java.lang.String getLoggerName()
ModuleDef
Logger
instance. This is typically the builder class name.getLoggerName
in interface ModuleDef
public ServiceDef getServiceDef(java.lang.String serviceId)
ModuleDef
ServiceDef2
, and will be converted to such if necessary.getServiceDef
in interface ModuleDef
serviceId
- the id of the service to retrieve (case is ignored)public java.util.Set<java.lang.String> getServiceIds()
ModuleDef
getServiceIds
in interface ModuleDef
${project.version} - Copyright © 2003-2015 The Apache Software Foundation.