Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
import android.text.TextUtils;

public class Main {

    public static boolean isEmpty(String str) {
        boolean result = false;
        if ("null".equals(str) || TextUtils.isEmpty(str)) {
            result = true;
        } else {
            if (TextUtils.isEmpty(str.trim())) {
                result = true;
            } else {
                result = false;
            }
        }
        return result;
    }
}