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 Details

  • Method Details

    • test

      boolean test(int value)
      Specified by:
      test in interface IntPredicate
    • 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 is false, then the other predicate 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 other predicate 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 other predicate
      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:
      negate in interface IntPredicate
      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 is true, then the other predicate 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 other predicate 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 other predicate
      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)