Code example for CharArrayWriter

Methods: toString

0
    public String toString()
    { 
        String throwableString = "NO THROWABLE ";
        if (hasThrowable()) 
        { 
            final CharArrayWriter out = new CharArrayWriter();
            throwable().printStackTrace(new PrintWriter(out));
            throwableString = out.toString();
        } 
 
        return format("Result : value=%s throwable=%s", value(), throwableString);
    } 
 
    public VALUE value() 
    { 
        return $1; 
    } 
}