Java Collection Contain containsAny(Collection src, Collection containsAny)

Here you can find the source of containsAny(Collection src, Collection containsAny)

Description

contains Any

License

Open Source License

Declaration

private static <T> boolean containsAny(Collection<T> src,
             Collection<T> containsAny) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import java.util.Collection;

public class Main {
    private static <T> boolean containsAny(Collection<T> src,
            Collection<T> containsAny) {
        for (T elem : containsAny) {
            if (src.contains(elem)) {
                return true;
            }/*from  ww w  .  j a v a2s.c om*/
        }
        return false;
    }
}

Related

  1. containsAny(Collection c, String... toCheck)
  2. containsAny(Collection strs, Collection searchTerms)
  3. containsAny(Collection collection, Collection query)
  4. containsAny(Collection collection, Collection toCheck)
  5. containsAny(Collection list, Collection values)
  6. containsAny(Collection firstCollection, Collection secondCollection)
  7. containsAny(final Collection a, final Collection b)
  8. containsAny(final Collection coll1, final Collection coll2)
  9. containsAny(final Collection collection, final Object... items)