Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;

import android.text.TextUtils;

import java.util.Collection;

public class Main {

    public static boolean isEmpty(Object obj) {
        return obj == null;
    }

    public static boolean isEmpty(Collection<?> collection) {
        return (collection == null || collection.size() == 0 || collection.isEmpty());
    }

    public static boolean isEmpty(String str) {
        return TextUtils.isEmpty(str);
    }
}