Package adams.flow.processor
Class ChangeRegExps
-
- All Implemented Interfaces:
Destroyable,GlobalInfoSupporter,LoggingLevelHandler,LoggingSupporter,OptionHandler,ShallowCopySupporter<ActorProcessor>,SizeOfHandler,ActorProcessor,ModifyingProcessor,Serializable,Comparable<ActorProcessor>
public class ChangeRegExps extends AbstractModifyingProcessor
Replaces regular expressions that match an old expression with the corresponding new one.- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected BaseRegExp[]m_NewExpressionsthe new expressions to replace with.protected BaseRegExp[]m_OldExpressionsthe old expressions to replace.-
Fields inherited from class adams.flow.processor.AbstractModifyingProcessor
m_Modified, m_ModifiedActor, m_NoCopy
-
Fields inherited from class adams.flow.processor.AbstractActorProcessor
m_Errors
-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description ChangeRegExps()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddefineOptions()Adds options to the internal list of options.BaseRegExp[]getNewExpressions()Returns the new expressions to replace with.BaseRegExp[]getOldExpressions()Returns the old expressions to replace.StringglobalInfo()Returns a string describing the object.StringnewExpressionsTipText()Returns the tip text for this property.StringoldExpressionsTipText()Returns the tip text for this property.protected voidprocessActor(Actor actor)Performs the actual processing.voidsetNewExpressions(BaseRegExp[] value)Sets the new expressions to replace with.voidsetOldExpressions(BaseRegExp[] value)Sets the old expressions to replace.-
Methods inherited from class adams.flow.processor.AbstractModifyingProcessor
getModifiedActor, getNoCopy, initialize, isModified, process, setNoCopy
-
Methods inherited from class adams.flow.processor.AbstractActorProcessor
addError, addError, checkData, compareTo, equals, getErrors, hasErrors, reset, shallowCopy, shallowCopy
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, loggingLevelTipText, newOptionManager, toCommandLine, toString
-
Methods inherited from class adams.core.logging.CustomLoggingLevelObject
setLoggingLevel
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.flow.processor.ActorProcessor
compareTo, getErrors, hasErrors, shallowCopy, shallowCopy
-
Methods inherited from interface adams.core.Destroyable
destroy
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel
-
Methods inherited from interface adams.core.option.OptionHandler
cleanUpOptions, getOptionManager, toCommandLine
-
-
-
-
Field Detail
-
m_OldExpressions
protected BaseRegExp[] m_OldExpressions
the old expressions to replace.
-
m_NewExpressions
protected BaseRegExp[] m_NewExpressions
the new expressions to replace with.
-
-
Method Detail
-
globalInfo
public String globalInfo()
Returns a string describing the object.- Specified by:
globalInfoin interfaceGlobalInfoSupporter- Specified by:
globalInfoin classAbstractOptionHandler- Returns:
- a description suitable for displaying in the gui
-
defineOptions
public void defineOptions()
Adds options to the internal list of options.- Specified by:
defineOptionsin interfaceOptionHandler- Overrides:
defineOptionsin classAbstractOptionHandler
-
setOldExpressions
public void setOldExpressions(BaseRegExp[] value)
Sets the old expressions to replace.- Parameters:
value- the old expressions
-
getOldExpressions
public BaseRegExp[] getOldExpressions()
Returns the old expressions to replace.- Returns:
- the old expressions
-
oldExpressionsTipText
public String oldExpressionsTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setNewExpressions
public void setNewExpressions(BaseRegExp[] value)
Sets the new expressions to replace with.- Parameters:
value- the new expressions
-
getNewExpressions
public BaseRegExp[] getNewExpressions()
Returns the new expressions to replace with.- Returns:
- the new expressions
-
newExpressionsTipText
public String newExpressionsTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
processActor
protected void processActor(Actor actor)
Performs the actual processing.- Specified by:
processActorin classAbstractActorProcessor- Parameters:
actor- the actor to process (is a copy of original for processors implementing ModifyingProcessor)- See Also:
ModifyingProcessor
-
-