private String writeGenericFailureInfo ( final Exec . Result result ) throws IOException { StringBuilder sb = new StringBuilder ( ) ; sb . append ( "graphviz process returned: " ) . append ( result . getStatus ( ) ) . append ( "\n" ) . append ( "stdout:\n" ) ; Files . lines ( result . getStdout ( ) ) . forEach ( sb :: append ) ; sb . append ( "stderr:\n" ) ; Files . lines ( result . getStderr ( ) ) . forEach ( sb :: append ) ; return sb . toString ( ) ; }
Writes error info to a String .