Uses of Interface
org.apache.commons.text.matcher.StringMatcher
Package
Description
Basic classes for text handling.
Provides algorithms for matching up strings for use with a
StringSubstitutor
.-
Uses of StringMatcher in org.apache.commons.text
Modifier and TypeFieldDescriptionstatic final StringMatcher
StringSubstitutor.DEFAULT_PREFIX
Constant for the default variable prefix.static final StringMatcher
StringSubstitutor.DEFAULT_SUFFIX
Constant for the default variable suffix.static final StringMatcher
StringSubstitutor.DEFAULT_VALUE_DELIMITER
Constant for the default value delimiter of a variable.Modifier and TypeMethodDescriptionStringTokenizer.getDelimiterMatcher()
Gets the field delimiter matcher.StringTokenizer.getIgnoredMatcher()
Gets the ignored character matcher.StringTokenizer.getQuoteMatcher()
Gets the quote matcher currently in use.StringTokenizer.getTrimmerMatcher()
Gets the trimmer character matcher.StringSubstitutor.getValueDelimiterMatcher()
Gets the variable default value delimiter matcher currently in use.StringSubstitutor.getVariablePrefixMatcher()
Gets the variable prefix matcher currently in use.StringSubstitutor.getVariableSuffixMatcher()
Gets the variable suffix matcher currently in use.Modifier and TypeMethodDescriptionboolean
TextStringBuilder.contains
(StringMatcher matcher) Tests if the string builder contains a string matched using the specified matcher.TextStringBuilder.deleteAll
(StringMatcher matcher) Deletes all parts of the builder that the matcher matches.TextStringBuilder.deleteFirst
(StringMatcher matcher) Deletes the first match within the builder using the specified matcher.int
TextStringBuilder.indexOf
(StringMatcher matcher) Searches the string builder using the matcher to find the first match.int
TextStringBuilder.indexOf
(StringMatcher matcher, int startIndex) Searches the string builder using the matcher to find the first match searching from the given index.int
TextStringBuilder.lastIndexOf
(StringMatcher matcher) Searches the string builder using the matcher to find the last match.int
TextStringBuilder.lastIndexOf
(StringMatcher matcher, int startIndex) Searches the string builder using the matcher to find the last match searching from the given index.TextStringBuilder.replace
(StringMatcher matcher, String replaceStr, int startIndex, int endIndex, int replaceCount) Advanced search and replaces within the builder using a matcher.TextStringBuilder.replaceAll
(StringMatcher matcher, String replaceStr) Replaces all matches within the builder with the replace string.TextStringBuilder.replaceFirst
(StringMatcher matcher, String replaceStr) Replaces the first match within the builder with the replace string.StringTokenizer.setDelimiterMatcher
(StringMatcher delim) Sets the field delimiter matcher.StringTokenizer.setIgnoredMatcher
(StringMatcher ignored) Sets the matcher for characters to ignore.StringTokenizer.setQuoteMatcher
(StringMatcher quote) Sets the quote matcher to use.StringTokenizer.setTrimmerMatcher
(StringMatcher trimmer) Sets the matcher for characters to trim.StringSubstitutor.setValueDelimiterMatcher
(StringMatcher valueDelimiterMatcher) Sets the variable default value delimiter matcher to use.StringSubstitutor.setVariablePrefixMatcher
(StringMatcher prefixMatcher) Sets the variable prefix matcher currently in use.StringSubstitutor.setVariableSuffixMatcher
(StringMatcher suffixMatcher) Sets the variable suffix matcher currently in use.ModifierConstructorDescriptionStringSubstitutor
(StringLookup variableResolver, StringMatcher prefixMatcher, StringMatcher suffixMatcher, char escape) Constructs a new initialized instance.StringSubstitutor
(StringLookup variableResolver, StringMatcher prefixMatcher, StringMatcher suffixMatcher, char escape, StringMatcher valueDelimiterMatcher) Constructs a new initialized instance.StringTokenizer
(char[] input, StringMatcher delim) Constructs a tokenizer splitting using the specified delimiter matcher.StringTokenizer
(char[] input, StringMatcher delim, StringMatcher quote) Constructs a tokenizer splitting using the specified delimiter matcher and handling quotes using the specified quote matcher.StringTokenizer
(String input, StringMatcher delim) Constructs a tokenizer splitting using the specified delimiter matcher.StringTokenizer
(String input, StringMatcher delim, StringMatcher quote) Constructs a tokenizer splitting using the specified delimiter matcher and handling quotes using the specified quote matcher. -
Uses of StringMatcher in org.apache.commons.text.matcher
Modifier and TypeMethodDescriptionStringMatcherFactory.andMatcher
(StringMatcher... stringMatchers) Creates a matcher that matches all of the given matchers in order.default StringMatcher
StringMatcher.andThen
(StringMatcher stringMatcher) Returns a matcher that matches this matcher followed by the given matcher.StringMatcherFactory.charMatcher
(char ch) Constructor that creates a matcher from a character.StringMatcherFactory.charSetMatcher
(char... chars) Constructor that creates a matcher from a set of characters.StringMatcherFactory.charSetMatcher
(String chars) Creates a matcher from a string representing a set of characters.StringMatcherFactory.commaMatcher()
Returns a matcher which matches the comma character.StringMatcherFactory.doubleQuoteMatcher()
Returns a matcher which matches the double quote character.StringMatcherFactory.noneMatcher()
Matches no characters.StringMatcherFactory.quoteMatcher()
Returns a matcher which matches the single or double quote character.StringMatcherFactory.singleQuoteMatcher()
Returns a matcher which matches the single quote character.StringMatcherFactory.spaceMatcher()
Returns a matcher which matches the space character.StringMatcherFactory.splitMatcher()
Matches the same characters as StringTokenizer, namely space, tab, newline and form feed.StringMatcherFactory.stringMatcher
(char... chars) Creates a matcher from a string.StringMatcherFactory.stringMatcher
(String str) Creates a matcher from a string.StringMatcherFactory.tabMatcher()
Returns a matcher which matches the tab character.StringMatcherFactory.trimMatcher()
Matches the String trim() whitespace characters.Modifier and TypeMethodDescriptionStringMatcherFactory.andMatcher
(StringMatcher... stringMatchers) Creates a matcher that matches all of the given matchers in order.default StringMatcher
StringMatcher.andThen
(StringMatcher stringMatcher) Returns a matcher that matches this matcher followed by the given matcher.