private void addCodeFromField(StringBuilder sb,Field f){
  try {
    sb.append(f.getName() + " = " + f.getInt(KeyEvent.class));
  }
 catch (  IllegalArgumentException e) {
    e.printStackTrace();
  }
catch (  IllegalAccessException e) {
    e.printStackTrace();
  }
  sb.append("\n");
}

private void addCodeFromField ( StringBuilder sb , Field f ) { try { sb . append ( f . getName ( ) + " = " + f . getInt ( KeyEvent . class ) ) ; } catch ( IllegalArgumentException e ) { e . printStackTrace ( ) ; } catch ( IllegalAccessException e ) { e . printStackTrace ( ) ; } sb . append ( "\n" ) ; }
add a new line of code that defines the field constant . the new line of code will be appended to an input string builder .
