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 {
    /**
     * Checks whether given collection is not null or non-empty.
     * @param c Colletion instance
     * @return true if not null or non-empty, otherwise false;
     */
    public static boolean isNullOrEmpty(Collection c) {
        return c == null || c.isEmpty();
    }
}