Package org.apache.struts2.convention
Class ClasspathConfigurationProvider
java.lang.Object
org.apache.struts2.convention.ClasspathConfigurationProvider
- All Implemented Interfaces:
com.opensymphony.xwork2.config.ConfigurationProvider
,com.opensymphony.xwork2.config.ContainerProvider
,com.opensymphony.xwork2.config.PackageProvider
,org.apache.struts2.dispatcher.DispatcherListener
public class ClasspathConfigurationProvider
extends Object
implements com.opensymphony.xwork2.config.ConfigurationProvider, org.apache.struts2.dispatcher.DispatcherListener
Xwork will only reload configurations, if one ContainerProvider needs reloading, that's all this class does
-
Constructor Summary
ConstructorsConstructorDescriptionClasspathConfigurationProvider
(com.opensymphony.xwork2.inject.Container container) -
Method Summary
Modifier and TypeMethodDescriptionvoid
destroy()
Not used.void
dispatcherDestroyed
(org.apache.struts2.dispatcher.Dispatcher du) void
dispatcherInitialized
(org.apache.struts2.dispatcher.Dispatcher du) void
init
(com.opensymphony.xwork2.config.Configuration configuration) Not used.void
Loads the packages using theActionConfigBuilder
.boolean
void
register
(com.opensymphony.xwork2.inject.ContainerBuilder containerBuilder, com.opensymphony.xwork2.util.location.LocatableProperties locatableProperties) Does nothing.void
setDevMode
(String mode) void
-
Constructor Details
-
ClasspathConfigurationProvider
public ClasspathConfigurationProvider(com.opensymphony.xwork2.inject.Container container)
-
-
Method Details
-
setDevMode
-
setReload
-
destroy
public void destroy()Not used.- Specified by:
destroy
in interfacecom.opensymphony.xwork2.config.ContainerProvider
-
init
public void init(com.opensymphony.xwork2.config.Configuration configuration) Not used.- Specified by:
init
in interfacecom.opensymphony.xwork2.config.ContainerProvider
- Specified by:
init
in interfacecom.opensymphony.xwork2.config.PackageProvider
- Parameters:
configuration
- configuration
-
register
public void register(com.opensymphony.xwork2.inject.ContainerBuilder containerBuilder, com.opensymphony.xwork2.util.location.LocatableProperties locatableProperties) throws com.opensymphony.xwork2.config.ConfigurationException Does nothing.- Specified by:
register
in interfacecom.opensymphony.xwork2.config.ContainerProvider
- Parameters:
containerBuilder
- container builderlocatableProperties
- locatable properties- Throws:
com.opensymphony.xwork2.config.ConfigurationException
- in case of configuration errors
-
loadPackages
public void loadPackages() throws com.opensymphony.xwork2.config.ConfigurationExceptionLoads the packages using theActionConfigBuilder
.- Specified by:
loadPackages
in interfacecom.opensymphony.xwork2.config.PackageProvider
- Throws:
com.opensymphony.xwork2.config.ConfigurationException
- in case of configuration errors
-
needsReload
public boolean needsReload()- Specified by:
needsReload
in interfacecom.opensymphony.xwork2.config.ContainerProvider
- Specified by:
needsReload
in interfacecom.opensymphony.xwork2.config.PackageProvider
- Returns:
- true if devMode, reload and actionConfigBuilder.needsReload()
-
dispatcherInitialized
public void dispatcherInitialized(org.apache.struts2.dispatcher.Dispatcher du) - Specified by:
dispatcherInitialized
in interfaceorg.apache.struts2.dispatcher.DispatcherListener
-
dispatcherDestroyed
public void dispatcherDestroyed(org.apache.struts2.dispatcher.Dispatcher du) - Specified by:
dispatcherDestroyed
in interfaceorg.apache.struts2.dispatcher.DispatcherListener
-