Class ModifyTextFileInArchive
- 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.ModifyTextFileInArchive
-
- All Implemented Interfaces:
DBHostable
,GeneralAction
,JEEHostable
,OSHostable
,Referenceable
public final class ModifyTextFileInArchive extends Action implements GeneralAction
Modifies text files within an archive (ZIP or JAR).
Note: Ensure the name and path to the file you specify matches, including case-sensitivity, to the name of the target file.
-
-
Constructor Summary
Constructors Constructor Description ModifyTextFileInArchive()
-
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
getEntryPath()
The path to the file in the archive to modify.java.lang.String
getExistingFile()
The existing file path the action should point to.FileType
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
getLineEndings()
The line ending to use.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
setEntryPath(java.lang.String entryPath)
The path to the file in the archive to modify.void
setExistingFile(java.lang.String existingFilePath)
The existing file path the action should point to.void
setFileTargetType(FileType 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
setLineEndings(LineEnding lineEndings)
The line ending to use.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.
-
setEntryPath
public void setEntryPath(java.lang.String entryPath)
The path to the file in the archive to modify.
-
getEntryPath
public java.lang.String getEntryPath()
The path to the file in the archive to modify.
-
setLineEndings
public void setLineEndings(LineEnding lineEndings)
The line ending to use.
-
getLineEndings
public LineEnding getLineEndings()
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.
-
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. This property is for internal use only and should not be set by the end user.
-
getBackup
public boolean getBackup()
Whether to create a backup of the file. This property is for internal use only and should not be set by the end user.
-
setFileTargetType
public void setFileTargetType(FileType type)
The file target type to use. Valid values are FileTargetType.INSTALLED and FileTargetType.EXISTING.
-
getFileTargetType
public FileType 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.
-
-