| java.lang.Object org.apache.derbyTesting.functionTests.util.streams.CharAlphabet
CharAlphabet | public class CharAlphabet (Code) | | A looping alphabet, returning characters.
The alphabet loops over a list of characters. The alphabet-object is used
by looping readers, which in turn is used for testing methods requiring
streaming inputs.
The following alphabets have been defined:
- Modern latin, lowercase ; letters a - z (26)
- Norwegian/Danish, lowercase ; letters a - z, plus three
additional letters (29)
- Tamil ; 46 Tamil letters from UNICODE U0B80
- CJK subset ; 12 letter from UNICODE CJK U4E00
|
Method Summary | |
public int | charCount() Return the number of characters in the alphabet. | public static CharAlphabet | cjkSubset() Get a CJK subset alphabet. | public String | getName() Return the name of the alphabet. | public static CharAlphabet | modernLatinLowercase() Get a modern latin lowercase alphabet. | public char | nextChar() Return the next char. | public int | nextCharAsInt() Return the next char as an integer . | public int | nextCharToRead(int charsRead) Compute the next character to read after reading the specified number
of characters. | public void | reset() Reset the alphabet, the next character returned will be the first
character in the alphabet. |
CJKSUBSET | public static char[] CJKSUBSET(Code) | | CJK subset; 12 letters, UNICODE U4E00
|
MODERNLATINLOWER | public static char[] MODERNLATINLOWER(Code) | | Modern latin, lowercase; a - z, 26 letters
|
NO_DK_LOWER | public static char[] NO_DK_LOWER(Code) | | Norwegian/Danish alphabet, lowercase; 29 letters
|
TAMIL | public static char[] TAMIL(Code) | | Subset of Tamil alphabet; 46 letters, UNICODE U0B80
|
charCount | public int charCount()(Code) | | Return the number of characters in the alphabet.
|
getName | public String getName()(Code) | | Return the name of the alphabet.
|
modernLatinLowercase | public static CharAlphabet modernLatinLowercase()(Code) | | Get a modern latin lowercase alphabet.
|
nextChar | public char nextChar()(Code) | | Return the next char.
the next character in the alphabet |
nextCharAsInt | public int nextCharAsInt()(Code) | | Return the next char as an integer .
the next character in the alphabet as an integer |
nextCharToRead | public int nextCharToRead(int charsRead)(Code) | | Compute the next character to read after reading the specified number
of characters.
Besides from returning the index, the internal state of
the alphabet is updated.
Parameters: charsRead - the number of characters read the index of the next character |
reset | public void reset()(Code) | | Reset the alphabet, the next character returned will be the first
character in the alphabet.
|
|
|