public class ExactPhraseRedaction extends TextRedaction
Represents a text redaction that replaces exact phrase in the document's text, case insensitive by default.
<b>Learn more</b>
Constructor and Description |
---|
ExactPhraseRedaction(String searchPhrase,
boolean isCaseSensitive,
ReplacementOptions options)
Initializes a new instance of ExactPhraseRedaction class.
|
ExactPhraseRedaction(String searchPhrase,
ReplacementOptions options)
Initializes a new instance of ExactPhraseRedaction class in case insensitive mode.
|
Modifier and Type | Method and Description |
---|---|
RedactorLogEntry |
applyTo(DocumentFormatInstance formatInstance)
Applies the redaction to a given format instance.
|
String |
getDescription()
Returns a string, describing the redaction and its parameters.
|
String |
getSearchPhrase()
Gets the string to search and replace.
|
boolean |
isCaseSensitive()
Gets a value indicating whether the search is case-sensitive or not.
|
getActionOptions
public ExactPhraseRedaction(String searchPhrase, ReplacementOptions options)
Initializes a new instance of ExactPhraseRedaction class in case insensitive mode.
searchPhrase
- String to search and replaceoptions
- Replacement options (textual, color)public ExactPhraseRedaction(String searchPhrase, boolean isCaseSensitive, ReplacementOptions options)
Initializes a new instance of ExactPhraseRedaction class.
searchPhrase
- String to search and replaceisCaseSensitive
- True if case sensitive search is requiredoptions
- Replacement options (textual, color)public final String getSearchPhrase()
Gets the string to search and replace.
public final boolean isCaseSensitive()
Gets a value indicating whether the search is case-sensitive or not.
public String getDescription()
Returns a string, describing the redaction and its parameters.
getDescription
in class Redaction
public RedactorLogEntry applyTo(DocumentFormatInstance formatInstance)
Applies the redaction to a given format instance.