JsonConfig config = new JsonConfig(); config.setJsonPropertyFilter(new PropertyFilter() { public boolean apply(Object source, String name, Object value) { if (name.equals("form") || name.equals("formElm") ) { return true; } else { return false; } } }); JSONObject jsonObject = JSONObject.fromObject( form, config );
|