Android examples for java.util:Collection
check Collection Emptiness
//package com.java2s; import java.util.Collection; public class Main { public static boolean checkCollectionEmptiness(Collection collection) { if (collection == null || collection.size() < 1) return true; else//from w ww.j a va 2 s. c o m return false; } public static boolean checkCollectionEmptiness(Object[] collection) { if (collection == null || collection.length < 1) return true; else return false; } }