Java Collection Check isCollectionType(Class type)

Here you can find the source of isCollectionType(Class type)

Description

is Collection Type

License

Open Source License

Declaration

public static <T> boolean isCollectionType(Class<T> type) 

Method Source Code

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

import java.util.Collection;

import java.util.Map;

public class Main {
    public static <T> boolean isCollectionType(Class<T> type) {
        return Collection.class.isAssignableFrom(type) || Map.class.isAssignableFrom(type);
    }/*from  w  w w.  j  a v a 2 s.c  om*/
}

Related

  1. isCollectionOrArrayType(Class typeToCheck)
  2. isCollectionType(Class aClass)
  3. isCollectionType(Class type)
  4. isCollectionType(Class cls)
  5. isCollectionType(Class cls)
  6. isCollectionType(final Class cls)
  7. isCollectionType(Object obj)
  8. isCollectionType(Object obj)
  9. isCollectionType(Object propertyValue)