Interface ObjCollection<E>

    • Method Detail

      • forEachWhile

        boolean forEachWhile​(Predicate<? super E> predicate)
        Checks the given predicate on each element in this collection until all elements have been processed or the predicate returns false for some element, or throws an Exception. Exceptions thrown by the predicate are relayed to the caller.

        The elements will be processed in the same order as they appear in Collection.iterator() and Iterable.forEach(java.util.function.Consumer<? super T>).

        If the collection is empty, this method returns true immediately.

        Parameters:
        predicate - the predicate to be checked for each element
        Returns:
        true if there are no elements in the collection, or if the predicate returned true for all elements of the collection, false if the predicate returned false for some element
        Throws:
        NullPointerException - if the specified predicate is null
        ConcurrentModificationException - if any structural modification of the collection (addition or removal of an element) is detected during iteration
        See Also:
        Iterable.forEach(java.util.function.Consumer<? super T>)
      • sizeAsLong

        long sizeAsLong()