Class ModifySingleTextFile
- java.lang.Object
-
- com.zerog.ia.auto.project.ProjectObject
-
- com.zerog.ia.auto.project.InstallableObject
-
- com.zerog.ia.auto.project.actions.Action
-
- com.zerog.ia.auto.project.actions.ModifySingleTextFile
-
- All Implemented Interfaces:
DBHostable
,GeneralAction
,JEEHostable
,OSHostable
,Referenceable
public final class ModifySingleTextFile extends Action implements GeneralAction
Modifies a text file on the target system.
-
-
Constructor Summary
Constructors Constructor Description ModifySingleTextFile()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getAdditionalText()
The additional text to use when performing the defined operation.boolean
getBackup()
Whether to create a backup of the file.java.lang.String
getExistingFile()
The existing file path the action should point to.ASCIIFileType
getFileTargetType()
The file target type to use.boolean
getIgnoreUnknownIAVariables()
Whether to ignore unknown IA variables in the file.FileAction
getInstalledFile()
The installed file the action should point to.LineEnding
getLineEndingsType()
The line ending to use.java.lang.String
getNewFilePath()
The path of the new file to create.java.util.Vector<KeyedData>
getSearchAndReplaceStrings()
The list of strings to search and replace.boolean
getSubstituteIAVariables()
Whether to substitute the IA variables in the file.TextOperation
getTextOperation()
The text operation to perform.void
setAdditionalText(java.lang.String additionalText)
The additional text to use when performing the defined operation.void
setBackup(boolean backup)
Whether to create a backup of the file.void
setExistingFile(java.lang.String existingFilePath)
The existing file path the action should point to.void
setFileTargetType(ASCIIFileType type)
The file target type to use.void
setIgnoreUnknownIAVariables(boolean ignoreUnknownIAVariables)
Whether to ignore unknown IA variables in the file.void
setInstalledFile(FileAction file)
The installed file the action should point to.void
setLineEndingsType(LineEnding lineEndings)
The line ending to use.void
setNewFilePath(java.lang.String t)
The path of the new file to create.void
setSearchAndReplaceStrings(java.util.Vector<KeyedData> searchReplaceStrings)
The list of strings to search and replace.void
setSubstituteIAVariables(boolean substitute)
Whether to substitute the IA variables in the file.void
setTextOperation(TextOperation textOperation)
The text operation to perform.-
Methods inherited from class com.zerog.ia.auto.project.InstallableObject
getBelongsToUninstallPhase, getRollbackEnabledCancel, getRollbackEnabledError, getRuleExpression, getRules, getRulesLogicalOperation, getTagsInInstallPiece, setBelongsToUninstallPhase, setRollbackEnabledCancel, setRollbackEnabledError, setRuleExpression, setRulesLogicalOperation, setTagsInInstallPiece
-
Methods inherited from class com.zerog.ia.auto.project.ProjectObject
equals, getReferenceID, hashCode, setReferenceID
-
-
-
-
Method Detail
-
setAdditionalText
public void setAdditionalText(java.lang.String additionalText)
The additional text to use when performing the defined operation.
-
getAdditionalText
public java.lang.String getAdditionalText()
The additional text to use when performing the defined operation.
-
setLineEndingsType
public void setLineEndingsType(LineEnding lineEndings)
The line ending to use.
-
getLineEndingsType
public LineEnding getLineEndingsType()
The line ending to use.
-
setTextOperation
public void setTextOperation(TextOperation textOperation)
The text operation to perform.
-
getTextOperation
public TextOperation getTextOperation()
The text operation to perform.
-
setInstalledFile
public void setInstalledFile(FileAction file)
The installed file the action should point to. To use this option the fileTargetType property should be set to FileTargetType.INSTALLED.- See Also:
#setFileTargetType(int)
-
getInstalledFile
public FileAction getInstalledFile()
The installed file the action should point to.
-
setExistingFile
public void setExistingFile(java.lang.String existingFilePath)
The existing file path the action should point to. To use this option the fileTargetType property should be set to FileTargetType.EXISTING.- See Also:
#setFileTargetType(int)
-
getExistingFile
public java.lang.String getExistingFile()
The existing file path the action should point to.
-
setNewFilePath
public void setNewFilePath(java.lang.String t)
The path of the new file to create. To use this option the fileTargetType property should be set to FileTargetType.CREATE.
-
getNewFilePath
public java.lang.String getNewFilePath()
The path of the new file to create.
-
setSubstituteIAVariables
public void setSubstituteIAVariables(boolean substitute)
Whether to substitute the IA variables in the file.
-
getSubstituteIAVariables
public boolean getSubstituteIAVariables()
Whether to substitute the IA variables in the file.
-
setIgnoreUnknownIAVariables
public void setIgnoreUnknownIAVariables(boolean ignoreUnknownIAVariables)
Whether to ignore unknown IA variables in the file.
-
getIgnoreUnknownIAVariables
public boolean getIgnoreUnknownIAVariables()
Whether to ignore unknown IA variables in the file.
-
setBackup
public void setBackup(boolean backup)
Whether to create a backup of the file.
-
getBackup
public boolean getBackup()
Whether to create a backup of the file.
-
setFileTargetType
public void setFileTargetType(ASCIIFileType type)
The file target type to use.
-
getFileTargetType
public ASCIIFileType getFileTargetType()
The file target type to use.
-
setSearchAndReplaceStrings
public void setSearchAndReplaceStrings(java.util.Vector<KeyedData> searchReplaceStrings)
The list of strings to search and replace. Expects aVector
ofKeyedData
where the propertyName is the string to search for and the propertyValue is the string to replace with.
-
getSearchAndReplaceStrings
public java.util.Vector<KeyedData> getSearchAndReplaceStrings()
The list of strings to search and replace.
-
-