public class DelimeterInserter extends Object
This is smart enough to merge areas when they overlap or exit side by side, and only one set of delimeters will be inserted.
| Constructor and Description |
|---|
DelimeterInserter(String frontDelimeter,
String endDelimeter)
Creates a DelimeterInserter that is in prefix mode and case insenstive.
|
DelimeterInserter(String frontDelimeter,
String endDelimeter,
boolean prefixMode)
Creates a DelimeterInserter that is case insenstive.
|
DelimeterInserter(String frontDelimeter,
String endDelimeter,
boolean prefixMode,
boolean caseInsensitive) |
| Modifier and Type | Method and Description |
|---|---|
String |
getConsideredWhitespace() |
String |
insert(String targetString,
String[] terms)
Called to do the actual delimeter intertion
|
void |
setConsideredWhitespace(String consideredWhitespace)
The String characters that can be considered whitespace ALONG with Character.iswhiteSpace().
|
public DelimeterInserter(String frontDelimeter, String endDelimeter)
frontDelimeter - the delimeter to use as around the front of a termendDelimeter - the delimeter to use as around the end of a termpublic DelimeterInserter(String frontDelimeter, String endDelimeter, boolean prefixMode)
frontDelimeter - the delimeter to use as around the front of a termendDelimeter - the delimeter to use as around the end of a termprefixMode - whether a match must be made on word boundariespublic DelimeterInserter(String frontDelimeter, String endDelimeter, boolean prefixMode, boolean caseInsensitive)
frontDelimeter - the delimeter to use as around the front of a termendDelimeter - the delimeter to use as around the end of a termprefixMode - whether a match must be made on word boundariescaseInsensitive - whether matching is case insenstivepublic String getConsideredWhitespace()
public void setConsideredWhitespace(String consideredWhitespace)
consideredWhitespace - the extra whitespace charactersCopyright © 2002-2019 Atlassian. All Rights Reserved.