Java Collection Add addAll(final T[] source, final Collection destination)

Here you can find the source of addAll(final T[] source, final Collection destination)

Description

add All

License

Open Source License

Declaration

public static <T> int addAll(final T[] source, final Collection<T> destination) 

Method Source Code

//package com.java2s;

import java.util.Collection;

public class Main {
    public static <T> int addAll(final T[] source, final Collection<T> destination) {
        int count = 0;
        for (final T sourceItem : source) {
            destination.add(sourceItem);
            ++count;//from  w  w w.  j a  v a2 s .  c o  m
        }

        return count;
    }
}

Related

  1. addAll(final Collection coll, final T... objs)
  2. addAll(final Collection collection, final T... elements)
  3. addAll(final Collection collection, final T... objects)
  4. addAll(final Collection collection, final T... objects)
  5. addAll(final Collection collection, final T[] items)
  6. addAll(final TCollection target, final Iterable source)
  7. addAll(Iterable iterable, Collection collection)
  8. addAll(Iterable iterable, Collection collection)
  9. addAll(S collection, T... values)