use of com.servoy.j2db.server.ngclient.property.ComponentTypeSabloValue in project servoy-client by Servoy.
the class FormComponentSabloValue method changesToJSON.
public void changesToJSON(JSONWriter writer, DataConversion clientConversion, FormComponentPropertyType formComponentPropertyType) {
clientConversion.convert(FormComponentPropertyType.TYPE_NAME);
writer.object();
writer.key("childElements");
writer.array();
DataConversion componentConversionMarkers = new DataConversion();
componentConversionMarkers.pushNode("childElements");
ComponentTypeSabloValue[] components = getComponents();
for (int i = 0; i < components.length; i++) {
componentConversionMarkers.pushNode(String.valueOf(i));
components[i].changesToJSON(writer, componentConversionMarkers, ComponentPropertyType.INSTANCE);
componentConversionMarkers.popNode();
}
componentConversionMarkers.popNode();
writer.endArray();
if (componentConversionMarkers.getConversions().size() > 0) {
writer.key(JSONUtils.TYPES_KEY).object();
JSONUtils.writeConversions(writer, componentConversionMarkers.getConversions());
writer.endObject();
}
writer.endObject();
}
Aggregations