Here you can find the source of isCollection(final Object obj)
public static boolean isCollection(final Object obj)
//package com.java2s; //License from project: Open Source License import java.util.Collection; public class Main { public static boolean isCollection(final Object obj) { return isInstanceof(obj, Collection.class); }//from w ww .j av a2 s.c om public static boolean isInstanceof(final Object obj, final Class<?> cls) { return cls.isInstance(obj); } }