code: public <T extends ElementType<E>> boolean positiveLookahead(T... expected) {
          for (ElementType<E> type : expected) {
              if (type.isMatchedBy(lookahead(1))) {
                  return true;
              }
          }
          return false;
      }
docs: Checks if the next element in this stream is of the expected types.
  
  @param <T> represents the element type of this stream, removes the
  "unchecked generic array creation for varargs parameter"
  warnings
  @param expected the expected types
  @return {@code true} if the next element is of the expected types
  or {@code false} otherwise