public static String formatProperties ( Properties properties ) { StringBuffer buf = new StringBuffer ( ) ; Set < Object > keySet = properties . keySet ( ) ; for ( Object key : keySet ) { buf . append ( key . toString ( ) . trim ( ) . toUpperCase ( ) . replaceAll ( " " , "_" ) ) ; buf . append ( "=" ) ; buf . append ( properties . get ( key ) ) ; buf . append ( System . getProperty ( "line.separator" ) ) ; } return buf . toString ( ) ; }
Format properties .