Class RbnfScannerProviderImpl.RbnfLenientScannerImpl
java.lang.Object
com.ibm.icu.impl.text.RbnfScannerProviderImpl.RbnfLenientScannerImpl
- All Implemented Interfaces:
RbnfLenientScanner
- Enclosing class:
RbnfScannerProviderImpl
private static class RbnfScannerProviderImpl.RbnfLenientScannerImpl
extends Object
implements RbnfLenientScanner
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns true if a string consists entirely of ignorable characters.int[]Searches a string for another string.int[]CLOVER:OFFintprefixLength(String str, String prefix) CLOVER:ON
-
Field Details
-
collator
-
-
Constructor Details
-
RbnfLenientScannerImpl
-
-
Method Details
-
allIgnorable
Description copied from interface:RbnfLenientScannerReturns true if a string consists entirely of ignorable characters.- Specified by:
allIgnorablein interfaceRbnfLenientScanner- Parameters:
s- The string to test- Returns:
- true if the string is empty or consists entirely of characters that are ignorable.
-
findText
Description copied from interface:RbnfLenientScannerSearches a string for another string. This might use a Collator to compare strings, or just do a simple match.- Specified by:
findTextin interfaceRbnfLenientScanner- Parameters:
str- The string to searchkey- The string to search "str" forstartingAt- The index into "str" where the search is to begin- Returns:
- A two-element array of ints. Element 0 is the position of the match, or -1 if there was no match. Element 1 is the number of characters in "str" that matched (which isn't necessarily the same as the length of "key")
-
findText2
-
prefixLength
CLOVER:ON- Specified by:
prefixLengthin interfaceRbnfLenientScanner- Parameters:
str- The string being testedprefix- The text we're hoping to see at the beginning of "str"- Returns:
- the number of characters in "str" that were matched
-