Package org.fife.ui.rtextarea
Class RegExReplaceInfo
- java.lang.Object
-
- org.fife.ui.rtextarea.RegExReplaceInfo
-
class RegExReplaceInfo extends java.lang.Object
Information on how to implement a regular expression "replace" operation.- Version:
- 1.0
-
-
Field Summary
Fields Modifier and Type Field Description private int
endIndex
private java.lang.String
matchedText
private java.lang.String
replacement
private int
startIndex
-
Constructor Summary
Constructors Constructor Description RegExReplaceInfo(java.lang.String matchedText, int start, int end, java.lang.String replacement)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getEndIndex()
Returns the end index of the matched text.java.lang.String
getMatchedText()
Returns the text that matched the regular expression.java.lang.String
getReplacement()
Returns the string to replace the matched text with.int
getStartIndex()
Returns the start index of the matched text.
-
-
-
Constructor Detail
-
RegExReplaceInfo
RegExReplaceInfo(java.lang.String matchedText, int start, int end, java.lang.String replacement)
Constructor.- Parameters:
matchedText
- The text that matched the regular expression.start
- The start index of the matched text in theCharSequence
searched.end
- The end index of the matched text in theCharSequence
searched.replacement
- The text to replace the matched text with. This string has any matched groups and character escapes replaced.
-
-
Method Detail
-
getEndIndex
public int getEndIndex()
Returns the end index of the matched text.- Returns:
- The end index of the matched text in the document searched.
- See Also:
getMatchedText()
,getEndIndex()
-
getMatchedText
public java.lang.String getMatchedText()
Returns the text that matched the regular expression.- Returns:
- The matched text.
-
getReplacement
public java.lang.String getReplacement()
Returns the string to replace the matched text with.- Returns:
- The string to replace the matched text with.
-
getStartIndex
public int getStartIndex()
Returns the start index of the matched text.- Returns:
- The start index of the matched text in the document searched.
- See Also:
getMatchedText()
,getEndIndex()
-
-