Java tutorial
//package com.java2s; public class Main { /** * Check out if it is a empty data * @param data String * @return true if is empty */ public static boolean isEmpty(CharSequence data) { return data == null || data.length() == 0; } }