public static StringBuilder formatErrors ( Collection < ? extends RoboconfError > errors , Log log ) { StringBuilder result = new StringBuilder ( ) ; for ( Map . Entry < RoboconfError , String > entry : RoboconfErrorHelpers . formatErrors ( errors , null , true ) . entrySet ( ) ) { if ( entry . getKey ( ) . getErrorCode ( ) . getLevel ( ) == ErrorLevel . WARNING ) log . warn ( entry . getValue ( ) ) ; else log . error ( entry . getValue ( ) ) ; result . append ( entry . getValue ( ) ) ; result . append ( "\n" ) ; } return result ; }
Formats a Roboconf errors and outputs it in the logs .