public static StringBuffer encodeToXML(Map map, boolean simple) { XMLEncoder writer = new XMLEncoder(); return (writer.encode(map, simple)); }