public abstract class AbstractPlugin extends ParameterHolder implements IPlugin, ITestPlugin, IWaitPlugin, ISleepPlugin, ITimedPlugin, IParalelPlugin
| Modifier and Type | Field and Description |
|---|---|
static String |
FEATURE_CONDITION
Default conditional feature.
|
static String |
FEATURE_NORMALIZED
Feature to set normalized state.
|
static String |
FEATURE_NORMALIZER
Feature to set string normalizer.
|
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.
|
parameters| Constructor and Description |
|---|
AbstractPlugin()
Default constructor.
|
| Modifier and Type | Method and Description |
|---|---|
IPlugin |
copy(IContext context)
Creates a copy of this plugin.
|
void |
doEnd(IContext context,
IResultSet result)
The end action.
|
ENext |
doStart(IContext context,
IResultSet result)
Performs the start action.
|
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.
|
IStringNormalizer |
getNormalizer()
Get a normalizer.
|
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 |
setNormalizer(IStringNormalizer normalizer)
Set normalizer.
|
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() |
getParameters, setParametersclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetParameters, setParametersgetActionTypepublic 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
public static final String FEATURE_NORMALIZER
public IPluginFactory getParent()
IPluginpublic void setParent(IPluginFactory parent)
IPluginpublic void initialize(IContext context) throws PluginException
IPlugininitialize in interface IPlugincontext - The test context.PluginException - On initialization errors.public ENext doStart(IContext context, IResultSet result) throws PluginException
IPlugindoStart in interface IPlugincontext - The context.result - The result set.PluginException - On execution errors.public void doEnd(IContext context, IResultSet result) throws PluginException
IPlugindoEnd in interface IPlugincontext - The context.result - The result set.PluginException - On execution errors.public IPlugin copy(IContext context) throws PluginException
IPlugincopy in interface IPlugincontext - The context.PluginException - On copy errors.public Boolean getCondition()
ITestPlugingetCondition in interface ITestPluginpublic void setCondition(Boolean condition)
ITestPluginsetCondition in interface ITestPlugincondition - The plugin condition.public IModel<Boolean> getConditionModel()
ITestPlugingetConditionModel in interface ITestPluginpublic void setConditionModel(IModel<Boolean> conditionModel)
ITestPluginsetConditionModel in interface ITestPluginconditionModel - The plugin condition model.public Long getWait()
IWaitPlugingetWait in interface IWaitPluginpublic void setWait(Long wait)
IWaitPluginsetWait in interface IWaitPluginwait - Wait time.public IModel<Long> getWaitModel()
IWaitPlugingetWaitModel in interface IWaitPluginpublic void setWaitModel(IModel<Long> waitModel)
IWaitPluginsetWaitModel in interface IWaitPluginwaitModel - The model.public Long getSleep()
ISleepPlugingetSleep in interface ISleepPluginpublic void setSleep(Long sleep)
ISleepPluginsetSleep in interface ISleepPluginsleep - Sleep time.public IModel<Long> getSleepModel()
ISleepPlugingetSleepModel in interface ISleepPluginpublic void setSleepModel(IModel<Long> sleepModel)
ISleepPluginsetSleepModel in interface ISleepPluginsleepModel - The model.public Long getTimeout()
ITimedPlugingetTimeout in interface ITimedPluginpublic void setTimeout(Long timeout)
ITimedPluginsetTimeout in interface ITimedPlugintimeout - The plugin timeout.public IModel<Long> getTimeoutModel()
ITimedPlugingetTimeoutModel in interface ITimedPluginpublic void setTimeoutModel(IModel<Long> timeoutModel)
ITimedPluginsetTimeoutModel in interface ITimedPlugintimeoutModel - A time model.public Boolean getThreadsafe()
IParalelPlugingetThreadsafe in interface IParalelPluginpublic void setThreadsafe(Boolean threadsafe)
IParalelPluginsetThreadsafe in interface IParalelPluginthreadsafe - The plugin thread safe flag.public Boolean getNormalized()
public void setNormalized(Boolean normalized)
normalized - true, to normalize, false, otherwise.public IStringNormalizer getNormalizer()
public void setNormalizer(IStringNormalizer normalizer)
normalizer - A normalizer.public String getNormalized(String str)
str - The string to be normalized.Copyright © 2016. All rights reserved.