|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.avalon.fortress.tools.FortressBean
Bean for making it easier to run Fortress, for example as Ant task.
Field Summary | |
static java.lang.String |
PROPERTY_CONTAINER_CLASS
|
static java.lang.String |
PROPERTY_CONTAINER_CONFIGURATION
|
static java.lang.String |
PROPERTY_CONTEXT_DIRECTORY
|
static java.lang.String |
PROPERTY_INSTRUMENT_MANAGER_CONFIGURATION
|
static java.lang.String |
PROPERTY_INVOKE_METHOD
|
static java.lang.String |
PROPERTY_LOGGER_MANAGER_CONFIGURATION
|
static java.lang.String |
PROPERTY_LOOKUP_COMPONENT_ROLE
|
static java.lang.String |
PROPERTY_ROLE_MANAGER_CONFIGURATION
|
static java.lang.String |
PROPERTY_SYSTEM_EXIT_ON_DISPOSE
|
static java.lang.String |
PROPERTY_WORK_DIRECTORY
|
Constructor Summary | |
FortressBean()
|
Method Summary | |
void |
dispose()
The dispose operation is called at the end of a components lifecycle. |
void |
enableLogging(Logger logger)
Provide component with a logger. |
void |
execute()
Implementation execute() method for Ant compatability. |
protected Logger |
getLogger()
|
protected ServiceManager |
getServiceManager()
|
void |
initialize()
Initialize the component. |
void |
initialize(java.util.Properties p)
|
static void |
main(java.lang.String[] args)
|
void |
run()
|
void |
service(ServiceManager sm)
Pass the ServiceManager to the Serviceable . |
void |
setContainerClass(java.lang.String containerClass)
The container implementation has to be a subclass of org.apache.avalon.fortress.impl.DefaultContainer . |
void |
setContainerConfiguration(java.lang.String containerConfiguration)
|
void |
setContextDirectory(java.lang.String contextDirectory)
|
void |
setInstrumentManagerConfiguration(java.lang.String instrumentManagerConfiguration)
|
void |
setInvokeMethod(java.lang.String invokeMethod)
|
void |
setLoggerManagerConfiguration(java.lang.String loggerManagerConfiguration)
|
void |
setLookupComponentRole(java.lang.String lookupComponentRole)
|
void |
setProperties(java.util.Properties properties)
|
void |
setRoleManagerConfiguration(java.lang.String roleManagerConfiguration)
|
void |
setSystemExitOnDispose(boolean systemExitOnDispose)
Should we call System.exit(0) after we are finished with processing. |
void |
setWorkDirectory(java.lang.String workDirectory)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String PROPERTY_CONTAINER_CLASS
public static final java.lang.String PROPERTY_CONTAINER_CONFIGURATION
public static final java.lang.String PROPERTY_CONTEXT_DIRECTORY
public static final java.lang.String PROPERTY_INSTRUMENT_MANAGER_CONFIGURATION
public static final java.lang.String PROPERTY_INVOKE_METHOD
public static final java.lang.String PROPERTY_LOGGER_MANAGER_CONFIGURATION
public static final java.lang.String PROPERTY_LOOKUP_COMPONENT_ROLE
public static final java.lang.String PROPERTY_ROLE_MANAGER_CONFIGURATION
public static final java.lang.String PROPERTY_SYSTEM_EXIT_ON_DISPOSE
public static final java.lang.String PROPERTY_WORK_DIRECTORY
Constructor Detail |
public FortressBean()
Method Detail |
public void enableLogging(Logger logger)
LogEnabled
enableLogging
in interface LogEnabled
logger
- the logger. Must not be null
.LogEnabled.enableLogging(org.apache.avalon.framework.logger.Logger)
protected final Logger getLogger()
public void initialize() throws java.lang.Exception
Initializable
initialize
in interface Initializable
java.lang.Exception
- if an error occursInitializable.initialize()
public void initialize(java.util.Properties p) throws java.lang.Exception
java.lang.Exception
public void run() throws java.lang.Exception
java.lang.Exception
public void execute()
public void service(ServiceManager sm) throws ServiceException
Serviceable
ServiceManager
to the Serviceable
.
The Serviceable
implementation should use the specified
ServiceManager
to acquire the components it needs for
execution.
service
in interface Serviceable
sm
- The ServiceManager
which this
Serviceable
uses. Must not be null
.
ServiceException
- if an error occursServiceable.service(org.apache.avalon.framework.service.ServiceManager)
public void dispose()
Disposable
dispose
in interface Disposable
Disposable.dispose()
protected ServiceManager getServiceManager()
public void setContainerClass(java.lang.String containerClass) throws java.lang.Exception
org.apache.avalon.fortress.impl.DefaultContainer
.
containerClass
- fully qualified class name of the container implementation class.
java.lang.Exception
public void setContainerConfiguration(java.lang.String containerConfiguration)
public void setContextDirectory(java.lang.String contextDirectory)
public void setInstrumentManagerConfiguration(java.lang.String instrumentManagerConfiguration)
public void setLoggerManagerConfiguration(java.lang.String loggerManagerConfiguration)
public void setRoleManagerConfiguration(java.lang.String roleManagerConfiguration)
public void setWorkDirectory(java.lang.String workDirectory)
public void setInvokeMethod(java.lang.String invokeMethod)
public void setLookupComponentRole(java.lang.String lookupComponentRole)
public void setSystemExitOnDispose(boolean systemExitOnDispose)
public static void main(java.lang.String[] args)
public void setProperties(java.util.Properties properties)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |