Examples of DateJsonValueProcessor


Examples of com.sogou.qadev.service.cynthia.util.DateJsonValueProcessor

    scriptVO.setAllowedTemplates(allowedTemplateIdsList);
    scriptVO.setActionIds(actionIdsList);
    scriptVO.setStatIds(statIdsList);
   
    JsonConfig config = new JsonConfig()
        config.registerJsonValueProcessor(Timestamp.class, new DateJsonValueProcessor());
        JSONObject json = JSONObject.fromObject(scriptVO,config);
        return json.toString();
  }
View Full Code Here

Examples of com.sogou.qadev.service.cynthia.util.DateJsonValueProcessor

  @RequestMapping("/getAllScript.do")
  @ResponseBody
  public String getAllScript() throws Exception {
    List<Script> scripts = das.queryAllScripts();
    JsonConfig config = new JsonConfig()
        config.registerJsonValueProcessor(Timestamp.class, new DateJsonValueProcessor());
    JSONArray json = JSONArray.fromObject(scripts,config);
    return json.toString();
  }
View Full Code Here

Examples of org.jrest4guice.rest.commons.json.DateJsonValueProcessor

  }

  public String toJson() {
    JsonConfig jsonConfig = JsonConfigFactory.createJsonConfig(this.content);
   
    jsonConfig.registerJsonValueProcessor(Date.class,new DateJsonValueProcessor());
    jsonConfig.registerJsonValueProcessor(Timestamp.class,new DateJsonValueProcessor())

    JsonConfigFactory.filteExcludes(this, jsonConfig);
    return JSONObject.fromObject(this,
        jsonConfig).toString();
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.