Here you can find the source of coerceToString(Object object)
public static String coerceToString(Object object)
//package com.java2s; //License from project: Open Source License public class Main { public static String coerceToString(Object object) { return coerceToString(object, null); }// w ww. ja va2s . c om public static String coerceToString(Object object, String defaultValue) { return (object != null) ? object.toString() : defaultValue; } }