Here you can find the source of emptyToNull(String value)
public static String emptyToNull(String value)
//package com.java2s; //License from project: Apache License public class Main { public static String emptyToNull(String value) { if (value.length() == 0) { return null; }/*from w ww.j a v a 2 s .co m*/ return value; } }