Here you can find the source of isEmpty(Object[] array)
Parameter | Description |
---|---|
array | a parameter |
public static boolean isEmpty(Object[] array)
//package com.java2s; import java.util.Collection; import java.util.Map; public class Main { /**//from ww w .j a v a 2 s . c o m * Method description * * * @param value * * @return */ public static boolean isEmpty(String value) { return (value == null) || (value.trim().length() == 0); } /** * Method description * * * @param collection * * @return */ public static boolean isEmpty(Collection<?> collection) { return (collection == null) || collection.isEmpty(); } /** * Method description * * * * @param map * * @return */ public static boolean isEmpty(Map<?, ?> map) { return (map == null) || map.isEmpty(); } /** * Method description * * * @param array * * @return */ public static boolean isEmpty(Object[] array) { return (array == null) || (array.length == 0); } }