Package com.vladsch.flexmark.util.misc
Interface CharPredicate
-
- All Superinterfaces:
IntPredicate
public interface CharPredicate extends IntPredicate
Interface for set of characters to use for inclusion exclusion tests Can be used for code points since the argument is int
-
-
Field Summary
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default @NotNull CharPredicateand(@NotNull CharPredicate other)Returns a composed predicate that represents a short-circuiting logical AND of this predicate and another.static @NotNull CharPredicateanyOf(char... chars)static @NotNull CharPredicateanyOf(@NotNull CharSequence chars)static intindexOf(@NotNull CharSequence thizz, char c)static intindexOf(@NotNull CharSequence thizz, char c, int fromIndex, int endIndex)default @NotNull CharPredicatenegate()Returns a predicate that represents the logical negation of this predicate.default @NotNull CharPredicateor(@NotNull CharPredicate other)Returns a composed predicate that represents a short-circuiting logical OR of this predicate and another.static @NotNull CharPredicatestandardOrAnyOf(char c1)static @NotNull CharPredicatestandardOrAnyOf(char c1, char c2)static @NotNull CharPredicatestandardOrAnyOf(char c1, char c2, char c3)static @NotNull CharPredicatestandardOrAnyOf(char c1, char c2, char c3, char c4)default booleantest(char value)booleantest(int value)-
Methods inherited from interface java.util.function.IntPredicate
and, or
-
-
-
-
Field Detail
-
NONE
static final CharPredicate NONE
-
ALL
static final CharPredicate ALL
-
SPACE
static final CharPredicate SPACE
-
TAB
static final CharPredicate TAB
-
EOL
static final CharPredicate EOL
-
ANY_EOL
static final CharPredicate ANY_EOL
-
ANY_EOL_NUL
static final CharPredicate ANY_EOL_NUL
-
BACKSLASH
static final CharPredicate BACKSLASH
-
SLASH
static final CharPredicate SLASH
-
LINE_SEP
static final CharPredicate LINE_SEP
-
HASH
static final CharPredicate HASH
-
SPACE_TAB
static final CharPredicate SPACE_TAB
-
SPACE_TAB_NUL
static final CharPredicate SPACE_TAB_NUL
-
SPACE_TAB_LINE_SEP
static final CharPredicate SPACE_TAB_LINE_SEP
-
SPACE_TAB_NBSP_LINE_SEP
static final CharPredicate SPACE_TAB_NBSP_LINE_SEP
-
SPACE_EOL
static final CharPredicate SPACE_EOL
-
SPACE_ANY_EOL
static final CharPredicate SPACE_ANY_EOL
-
SPACE_TAB_NBSP
static final CharPredicate SPACE_TAB_NBSP
-
SPACE_TAB_EOL
static final CharPredicate SPACE_TAB_EOL
-
SPACE_TAB_NBSP_EOL
static final CharPredicate SPACE_TAB_NBSP_EOL
-
WHITESPACE
static final CharPredicate WHITESPACE
-
WHITESPACE_OR_NUL
static final CharPredicate WHITESPACE_OR_NUL
-
WHITESPACE_NBSP
static final CharPredicate WHITESPACE_NBSP
-
WHITESPACE_NBSP_OR_NUL
static final CharPredicate WHITESPACE_NBSP_OR_NUL
-
BLANKSPACE
static final CharPredicate BLANKSPACE
-
HEXADECIMAL_DIGITS
static final CharPredicate HEXADECIMAL_DIGITS
-
DECIMAL_DIGITS
static final CharPredicate DECIMAL_DIGITS
-
OCTAL_DIGITS
static final CharPredicate OCTAL_DIGITS
-
BINARY_DIGITS
static final CharPredicate BINARY_DIGITS
-
FALSE
@Deprecated static final CharPredicate FALSE
Deprecated.
-
TRUE
@Deprecated static final CharPredicate TRUE
Deprecated.
-
SPACE_TAB_OR_NUL
@Deprecated static final CharPredicate SPACE_TAB_OR_NUL
Deprecated.
-
-
Method Detail
-
test
boolean test(int value)
- Specified by:
testin interfaceIntPredicate
-
test
default boolean test(char value)
-
and
@NotNull default @NotNull CharPredicate and(@NotNull @NotNull CharPredicate other)
Returns a composed predicate that represents a short-circuiting logical AND of this predicate and another. When evaluating the composed predicate, if this predicate isfalse, then theotherpredicate is not evaluated.Any exceptions thrown during evaluation of either predicate are relayed to the caller; if evaluation of this predicate throws an exception, the
otherpredicate will not be evaluated.- Parameters:
other- a predicate that will be logically-ANDed with this predicate- Returns:
- a composed predicate that represents the short-circuiting logical
AND of this predicate and the
otherpredicate - Throws:
NullPointerException- if other is null
-
negate
@NotNull default @NotNull CharPredicate negate()
Returns a predicate that represents the logical negation of this predicate.- Specified by:
negatein interfaceIntPredicate- Returns:
- a predicate that represents the logical negation of this predicate
-
or
@NotNull default @NotNull CharPredicate or(@NotNull @NotNull CharPredicate other)
Returns a composed predicate that represents a short-circuiting logical OR of this predicate and another. When evaluating the composed predicate, if this predicate istrue, then theotherpredicate is not evaluated.Any exceptions thrown during evaluation of either predicate are relayed to the caller; if evaluation of this predicate throws an exception, the
otherpredicate will not be evaluated.- Parameters:
other- a predicate that will be logically-ORed with this predicate- Returns:
- a composed predicate that represents the short-circuiting logical
OR of this predicate and the
otherpredicate - Throws:
NullPointerException- if other is null
-
standardOrAnyOf
@NotNull static @NotNull CharPredicate standardOrAnyOf(char c1)
-
standardOrAnyOf
@NotNull static @NotNull CharPredicate standardOrAnyOf(char c1, char c2)
-
standardOrAnyOf
@NotNull static @NotNull CharPredicate standardOrAnyOf(char c1, char c2, char c3)
-
standardOrAnyOf
@NotNull static @NotNull CharPredicate standardOrAnyOf(char c1, char c2, char c3, char c4)
-
anyOf
@NotNull static @NotNull CharPredicate anyOf(char... chars)
-
indexOf
static int indexOf(@NotNull @NotNull CharSequence thizz, char c)
-
indexOf
static int indexOf(@NotNull @NotNull CharSequence thizz, char c, int fromIndex, int endIndex)
-
anyOf
@NotNull static @NotNull CharPredicate anyOf(@NotNull @NotNull CharSequence chars)
-
-