Class AbstractConfiguration
- java.lang.Object
-
- org.codehaus.cargo.util.log.LoggedObject
-
- org.codehaus.cargo.container.spi.configuration.AbstractConfiguration
-
- All Implemented Interfaces:
Configuration
,ContainerConfiguration
,Loggable
- Direct Known Subclasses:
AbstractLocalConfiguration
,AbstractRuntimeConfiguration
public abstract class AbstractConfiguration extends LoggedObject implements ContainerConfiguration, Configuration
Base implementation ofContainerConfiguration
that can be specialized for any type of configuration.
-
-
Constructor Summary
Constructors Constructor Description AbstractConfiguration()
Default setup.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<String,String>
getProperties()
String
getPropertyValue(String name)
void
setProperty(String name, String value)
A property is a configuration value for the container (eg the web port, the number of executing threads, etc).void
verify()
Verify that the configuration is valid.-
Methods inherited from class org.codehaus.cargo.util.log.LoggedObject
getLogger, setLogger
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.codehaus.cargo.container.configuration.Configuration
getCapability, getType
-
-
-
-
Method Detail
-
setProperty
public void setProperty(String name, String value)
A property is a configuration value for the container (eg the web port, the number of executing threads, etc).- Specified by:
setProperty
in interfaceConfiguration
- Parameters:
name
- the property namevalue
- the property value
-
getProperties
public Map<String,String> getProperties()
- Specified by:
getProperties
in interfaceConfiguration
- Returns:
- the list of properties set
- See Also:
Configuration.setProperty(String, String)
-
getPropertyValue
public String getPropertyValue(String name)
- Specified by:
getPropertyValue
in interfaceConfiguration
- Parameters:
name
- the property name for which to return the value- Returns:
- the property's value
- See Also:
Configuration.setProperty(String, String)
-
verify
public void verify()
Verify that the configuration is valid. The checks to be performed may vay whether this is standalone or existing configuration. This method should also be used to verify that the configuration properties specified by the user are valid and that the required ones are set.- Specified by:
verify
in interfaceContainerConfiguration
-
-