|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.specrunner.parameters.core.ParameterHolder
org.specrunner.plugins.core.AbstractPlugin
public abstract class AbstractPlugin
Adapter for plugins.
| Field Summary | |
|---|---|
static String |
FEATURE_CONDITION
Default conditional feature. |
static String |
FEATURE_NORMALIZED
Feature to set normalized state. |
static String |
FEATURE_SLEEP
Default sleep time feature. |
static String |
FEATURE_THREADSAFE
Default threadsafe feature. |
static String |
FEATURE_TIMEOUT
Default timeout time feature. |
static String |
FEATURE_WAIT
Default wait time feature. |
| Constructor Summary | |
|---|---|
AbstractPlugin()
Default constructor. |
|
| Method Summary | |
|---|---|
IPlugin |
copy(IContext context)
Creates a copy of this plugin. |
void |
doEnd(IContext context,
IResultSet result)
The end action. i.e. after a loop specification perform something in a newly generated table. |
ENext |
doStart(IContext context,
IResultSet result)
Performs the start action. i.e. create a database schema. |
Boolean |
getCondition()
Get the plugin execution condition. |
IModel<Boolean> |
getConditionModel()
Get the plugin execution condition model. |
Boolean |
getNormalized()
If normalized is false, the expected and received String are not compared using their normalized version (trim+remove extra spaces). |
String |
getNormalized(String str)
Get the normalized version of a string. |
IPluginFactory |
getParent()
Get the plugin factory source. |
Long |
getSleep()
The plugin timeout. |
IModel<Long> |
getSleepModel()
Return the sleep based on a model. |
Boolean |
getThreadsafe()
The plugin thread safe status. |
Long |
getTimeout()
The plugin timeout. |
IModel<Long> |
getTimeoutModel()
Model for timeout testing. |
Long |
getWait()
The plugin wait time. |
IModel<Long> |
getWaitModel()
Return the wait based on a model. |
void |
initialize(IContext context)
Initialize the plugin. |
void |
setCondition(Boolean condition)
Set plugin condition. |
void |
setConditionModel(IModel<Boolean> conditionModel)
Set plugin condition model. |
void |
setNormalized(Boolean normalized)
Set the normalized state. |
void |
setParent(IPluginFactory parent)
Set the plugin factory (where it came from). |
void |
setSleep(Long sleep)
Gets time to sleep in milliseconds after test action. |
void |
setSleepModel(IModel<Long> sleepModel)
Set sleep model object. |
void |
setThreadsafe(Boolean threadsafe)
Set the thread safe status. |
void |
setTimeout(Long timeout)
Set the plugin timeout. |
void |
setTimeoutModel(IModel<Long> timeoutModel)
Set the model. |
void |
setWait(Long wait)
Gets time to sleep in milliseconds before test action. |
void |
setWaitModel(IModel<Long> waitModel)
Set wait model object. |
String |
toString()
|
| Methods inherited from class org.specrunner.parameters.core.ParameterHolder |
|---|
getParameters, setParameters |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.specrunner.parameters.IParameterHolder |
|---|
getParameters, setParameters |
| Methods inherited from interface org.specrunner.plugins.IActionType |
|---|
getActionType |
| Field Detail |
|---|
public static final String FEATURE_CONDITION
public static final String FEATURE_WAIT
public static final String FEATURE_SLEEP
public static final String FEATURE_TIMEOUT
public static final String FEATURE_THREADSAFE
public static final String FEATURE_NORMALIZED
| Constructor Detail |
|---|
public AbstractPlugin()
| Method Detail |
|---|
public IPluginFactory getParent()
IPlugin
getParent in interface IPluginpublic void setParent(IPluginFactory parent)
IPlugin
setParent in interface IPluginparent - The factory.
public void initialize(IContext context)
throws PluginException
IPlugin
initialize in interface IPlugincontext - The test context.
PluginException - On initialization errors.
public ENext doStart(IContext context,
IResultSet result)
throws PluginException
IPlugin
doStart in interface IPlugincontext - The context.result - The result set.
PluginException - On execution errors.
public void doEnd(IContext context,
IResultSet result)
throws PluginException
IPlugin
doEnd in interface IPlugincontext - The context.result - The result set.
PluginException - On execution errors.
public IPlugin copy(IContext context)
throws PluginException
IPlugin
copy in interface IPlugincontext - The context.
PluginException - On copy errors.public Boolean getCondition()
ITestPlugin
getCondition in interface ITestPluginpublic void setCondition(Boolean condition)
ITestPlugin
setCondition in interface ITestPlugincondition - The plugin condition.public IModel<Boolean> getConditionModel()
ITestPlugin
getConditionModel in interface ITestPluginpublic void setConditionModel(IModel<Boolean> conditionModel)
ITestPlugin
setConditionModel in interface ITestPluginconditionModel - The plugin condition model.public Long getWait()
IWaitPlugin
getWait in interface IWaitPluginpublic void setWait(Long wait)
IWaitPlugin
setWait in interface IWaitPluginwait - Wait time.public IModel<Long> getWaitModel()
IWaitPlugin
getWaitModel in interface IWaitPluginpublic void setWaitModel(IModel<Long> waitModel)
IWaitPlugin
setWaitModel in interface IWaitPluginwaitModel - The model.public Long getSleep()
ISleepPlugin
getSleep in interface ISleepPluginpublic void setSleep(Long sleep)
ISleepPlugin
setSleep in interface ISleepPluginsleep - Sleep time.public IModel<Long> getSleepModel()
ISleepPlugin
getSleepModel in interface ISleepPluginpublic void setSleepModel(IModel<Long> sleepModel)
ISleepPlugin
setSleepModel in interface ISleepPluginsleepModel - The model.public Long getTimeout()
ITimedPlugin
getTimeout in interface ITimedPluginpublic void setTimeout(Long timeout)
ITimedPlugin
setTimeout in interface ITimedPlugintimeout - The plugin timeout.public IModel<Long> getTimeoutModel()
ITimedPlugin
getTimeoutModel in interface ITimedPluginpublic void setTimeoutModel(IModel<Long> timeoutModel)
ITimedPlugin
setTimeoutModel in interface ITimedPlugintimeoutModel - A time model.public Boolean getThreadsafe()
IParalelPlugin
getThreadsafe in interface IParalelPluginpublic void setThreadsafe(Boolean threadsafe)
IParalelPlugin
setThreadsafe in interface IParalelPluginthreadsafe - The plugin thread safe flag.public Boolean getNormalized()
public void setNormalized(Boolean normalized)
normalized - true, to normalize, false, otherwise.public String getNormalized(String str)
str - The string to be normalized.
public String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||