public String toJSON(boolean prettyPrint) throws JsonGenerationException, JsonMappingException, IOException {
  String json=null;
  ObjectMapper mapper=new ObjectMapper();
  mapper.configure(Feature.INDENT_OUTPUT,true);
  mapper.configure(Feature.SORT_PROPERTIES_ALPHABETICALLY,true);
  ObjectWriter writer=mapper.writer();
  if (prettyPrint)   writer=writer.withDefaultPrettyPrinter();
  json=writer.writeValueAsString(this);
  return json;
}

public String toJSON ( boolean prettyPrint ) throws JsonGenerationException , JsonMappingException , IOException { String json = null ; ObjectMapper mapper = new ObjectMapper ( ) ; mapper . configure ( Feature . INDENT_OUTPUT , true ) ; mapper . configure ( Feature . SORT_PROPERTIES_ALPHABETICALLY , true ) ; ObjectWriter writer = mapper . writer ( ) ; if ( prettyPrint ) writer = writer . withDefaultPrettyPrinter ( ) ; json = writer . writeValueAsString ( this ) ; return json ; }
serialize the tungstenproperties into a json string
