|
||||||||||
PREV NEXT | FRAMES NO FRAMES |
Packages that use CharPredicate | |
---|---|
jfun.parsec | Provides classes and interfaces for parser combinator logic and basic parsers. |
jfun.parsec.pattern | Provides classes and interfaces for pattern combinator logic and basic patterns. |
Uses of CharPredicate in jfun.parsec |
---|
Methods in jfun.parsec with parameters of type CharPredicate | |
---|---|
static Parser<_> |
Scanners.isChar(CharPredicate cp)
succeed and consume the current character if it satisfies the given CharPredicate. |
static Parser<_> |
Scanners.isChar(CharPredicate cp,
java.lang.String err)
succeed and consume the current character if it satisfies the given CharPredicate. |
static Parser<_> |
Scanners.isChar(java.lang.String name,
CharPredicate cp)
succeed and consume the current character if it satisfies the given CharPredicate. |
static Parser<_> |
Scanners.isChar(java.lang.String name,
CharPredicate cp,
java.lang.String err)
succeed and consume the current character if it satisfies the given CharPredicate. |
static Parser<_> |
Scanners.many(CharPredicate cp)
Scans greedily for 0 or more characters that satisfies the given CharPredicate. |
static Parser<_> |
Scanners.many(java.lang.String name,
CharPredicate cp)
Scans greedily for 0 or more characters that satisfies the given CharPredicate. |
static Parser<_> |
Scanners.many1(CharPredicate cp)
Scans greedily for 1 or more characters that satisfies the given CharPredicate. |
static Parser<_> |
Scanners.many1(java.lang.String name,
CharPredicate cp)
Scans greedily for 1 or more characters that satisfies the given CharPredicate. |
Uses of CharPredicate in jfun.parsec.pattern |
---|
Methods in jfun.parsec.pattern that return CharPredicate | |
---|---|
static CharPredicate |
CharPredicates.always()
A predicate that always returns true. |
static CharPredicate |
CharPredicates.among(char[] chars)
among chars. |
static CharPredicate |
CharPredicates.and(CharPredicate... cps)
Logical and of an array of CharPredicate objects. |
static CharPredicate |
CharPredicates.and(CharPredicate cp1,
CharPredicate cp2)
Logical and of two CharPredicate objects. |
static CharPredicate |
CharPredicates.isAlpha_()
[a-zA-Z_]. |
static CharPredicate |
CharPredicates.isAlpha()
[a-zA-Z]. |
static CharPredicate |
CharPredicates.isAlphaNumeric()
[a-zA-Z0-9_] |
static CharPredicate |
CharPredicates.isChar(char a)
== a. |
static CharPredicate |
CharPredicates.isDigit()
between 0 and 9. |
static CharPredicate |
CharPredicates.isHexDigit()
is hex digit. |
static CharPredicate |
CharPredicates.isLetter()
is letter. |
static CharPredicate |
CharPredicates.isLowercase()
[a-z]. |
static CharPredicate |
CharPredicates.isUppercase()
[A-Z]. |
static CharPredicate |
CharPredicates.isWhitespace()
is white space. |
static CharPredicate |
CharPredicates.never()
A predicate that always returns false. |
static CharPredicate |
CharPredicates.not(CharPredicate cp)
Negate a CharPredicate object. |
static CharPredicate |
CharPredicates.notAmong(char[] chars)
not among chars. |
static CharPredicate |
CharPredicates.notChar(char a)
!= a. |
static CharPredicate |
CharPredicates.notRange(char a,
char b)
not between a and b inclusive. |
static CharPredicate |
CharPredicates.or(CharPredicate... cps)
Logical or of an array of CharPredicate objects. |
static CharPredicate |
CharPredicates.or(CharPredicate cp1,
CharPredicate cp2)
Logical or of two CharPredicate objects. |
static CharPredicate |
CharPredicates.range(char a,
char b)
between a and b inclusive. |
Methods in jfun.parsec.pattern with parameters of type CharPredicate | |
---|---|
static CharPredicate |
CharPredicates.and(CharPredicate... cps)
Logical and of an array of CharPredicate objects. |
static CharPredicate |
CharPredicates.and(CharPredicate cp1,
CharPredicate cp2)
Logical and of two CharPredicate objects. |
static Pattern |
Patterns.isChar(CharPredicate cp)
Succeed with match length 1 if the current character in the input satisfies the given predicate. |
static Pattern |
Patterns.many(CharPredicate cp)
Matches 0 or more characters that all satisfy the given predicate. |
static Pattern |
Patterns.many(int min,
CharPredicate cp)
Matches if the input starts with min or more characters that all satisfy the given predicate, mismatch otherwise. |
static Pattern |
Patterns.many1(CharPredicate cp)
Matches characters that satisfies the given predicate for 1 or more times. |
static CharPredicate |
CharPredicates.not(CharPredicate cp)
Negate a CharPredicate object. |
static CharPredicate |
CharPredicates.or(CharPredicate... cps)
Logical or of an array of CharPredicate objects. |
static CharPredicate |
CharPredicates.or(CharPredicate cp1,
CharPredicate cp2)
Logical or of two CharPredicate objects. |
static Pattern |
Patterns.repeat(int n,
CharPredicate cp)
Matches if the input has at least n characters and the first n characters all satisfy the given predicate. |
static Pattern |
Patterns.some(int max,
CharPredicate cp)
Matches at most max number of characters that satisfies the given predicate. |
static Pattern |
Patterns.some(int min,
int max,
CharPredicate cp)
Matches at least min and at most max number of characters that satisfies the given predicate, mismatch otherwise. |
|
||||||||||
PREV NEXT | FRAMES NO FRAMES |