public static String unescapeString ( String escapedString ) { StringBuilder sb = new StringBuilder ( ) ; for ( int i = 1 ; i < escapedString . length ( ) - 1 ; ++ i ) { char c = escapedString . charAt ( i ) ; if ( c == ' ' ) { ++ i ; sb . append ( unescapeChar ( escapedString . charAt ( i ) ) ) ; } else { sb . append ( c ) ; } } return sb . toString ( ) ; }
Replaces all the printf - style escape sequences in a string with the appropriate characters .