Tabnine Logo
IterableUtils.zippingIterable
Code IndexAdd Tabnine to your IDE (free)

How to use
zippingIterable
method
in
org.apache.commons.collections4.IterableUtils

Best Java code snippets using org.apache.commons.collections4.IterableUtils.zippingIterable (Showing top 2 results out of 315)

origin: org.apache.commons/commons-collections4

/**
 * Returns a new FluentIterable whose iterator will traverse
 * the elements of this iterable and the other iterable in
 * alternating order.
 *
 * @param other  the other iterable to interleave, may not be null
 * @return a new iterable, interleaving this iterable with others
 * @throws NullPointerException if other is null
 */
public FluentIterable<E> zip(final Iterable<? extends E> other) {
  return of(IterableUtils.zippingIterable(iterable, other));
}
origin: org.apache.commons/commons-collections4

/**
 * Returns a new FluentIterable whose iterator will traverse
 * the elements of this iterable and the other iterables in
 * alternating order.
 *
 * @param others  the iterables to interleave, may not be null
 * @return a new iterable, interleaving this iterable with others
 * @throws NullPointerException if either of the provided iterables is null
 */
public FluentIterable<E> zip(final Iterable<? extends E>... others) {
  return of(IterableUtils.zippingIterable(iterable, others));
}
org.apache.commons.collections4IterableUtilszippingIterable

Javadoc

Interleaves two iterables into a single iterable.

The returned iterable has an iterator that traverses the elements in aand b in alternating order. The source iterators are not polled until necessary.

The returned iterable's iterator supports remove() when the corresponding input iterator supports it.

Popular methods of IterableUtils

  • find
    Finds the first element in the given iterable which matches the given predicate. A null or empty it
  • get
    Returns the index-th value in the iterable's Iterator, throwing IndexOutOfBoundsException if there i
  • forEach
    Applies the closure to each element of the provided iterable.
  • isEmpty
    Answers true if the provided iterable is empty. A null iterable returns true.
  • matchesAny
    Answers true if a predicate is true for any element of the iterable. A null or empty iterable return
  • countMatches
    Counts the number of elements in the input iterable that match the predicate. A null iterable matche
  • emptyIterable
    Gets an empty iterable. This iterable does not contain any elements.
  • forEachButLast
    Executes the given closure on each but the last element in the iterable. If the input iterable is nu
  • indexOf
    Returns the index of the first element in the specified iterable that matches the given predicate. A
  • toList
    Gets a new list with the contents of the provided iterable.
  • boundedIterable
    Returns a view of the given iterable that contains at most the given number of elements. The returne
  • chainedIterable
    Combines the provided iterables into a single iterable. The returned iterable has an iterator that t
  • boundedIterable,
  • chainedIterable,
  • checkNotNull,
  • collatedIterable,
  • contains,
  • emptyIfNull,
  • emptyIteratorIfNull,
  • filteredIterable,
  • frequency,
  • loopingIterable

Popular in Java

  • Parsing JSON documents to java classes using gson
  • setContentView (Activity)
  • notifyDataSetChanged (ArrayAdapter)
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • FlowLayout (java.awt)
    A flow layout arranges components in a left-to-right flow, much like lines of text in a paragraph. F
  • RandomAccessFile (java.io)
    Allows reading from and writing to a file in a random-access manner. This is different from the uni-
  • TreeSet (java.util)
    TreeSet is an implementation of SortedSet. All optional operations (adding and removing) are support
  • Callable (java.util.concurrent)
    A task that returns a result and may throw an exception. Implementors define a single method with no
  • ZipFile (java.util.zip)
    This class provides random read access to a zip file. You pay more to read the zip file's central di
  • JPanel (javax.swing)
  • Top PhpStorm plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now