src/main/java/ognl/OgnlOps.java
public static String stringValue(Object value, boolean trim)
    {
        String result;

        if (value == null) {
            result = OgnlRuntime.NULL_STRING;
        } else {
            result = value.toString();
            if (trim) {
                result = result.trim();
            }
        }
        return result;
    }
public static String stringValue(Object value, boolean trim)
    {
        String result;

        if (value == null) {
            result = OgnlRuntime.NULL_STRING;
        } else {
            result = value.toString();
            if (trim) {
                result = result.trim();
            }
        }
        return result;
    }
public static String stringValue ( Object value , boolean trim ) { String result ; if ( value == null ) { result = OgnlRuntime . NULL_STRING ; } else { result = value . toString ( ) ; if ( trim ) { result = result . trim ( ) ; } } return result ; }
Evaluates the given object as a String and trims it if the trim flag is true.

@param value
an object to interpret as a String
@return the String value implied by the given object as returned by the toString() method, or
"null" if the object is null.
Evaluates the given object as a String and trims it if the trim flag is true .