Class type = (Class) en.getMethod("getType").invoke(v);
String subsection = key.substring(0, key.indexOf('.'));
if (!lastSection.equals(subsection)) {
if (gen.getOutputContext().inArray()) gen.writeEndArray();
gen.writeFieldName(subsection); // "sectionName":
gen.writeStartArray(); // [
lastSection = subsection;
}
boolean isOverridden = (Boolean)(en.getMethod("isOverridden")).invoke(v);
gen.writeStartObject(); // {
gen.writeStringField(key,valueAsString); // "key": "value"