Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;

import java.util.Collection;

public class Main {
    public static boolean isNullOrEmpty(Collection<?> list) {
        return list == null || list.size() == 0;
    }

    public static <T> boolean isNullOrEmpty(T... array) {
        return array == null || array.length == 0;
    }

    public static boolean isNullOrEmpty(int... args) {
        return args == null || args.length == 0;
    }
}