title: Generate JSON sample from POJO
body: <p>We are looking for a way (maybe existing framework or similar) to generate sample JSON fragments based on POJOs (source or binary). For example:</p>
  
  <pre><code>public class foo {
     String var1;
     String var2;
  
     public String getVar1() { return var1; }
     public void setVar1(String var1) { this.var1 = var1; }
  
     public String getVar2() { return var2; }
     public void setVar2(String var2) { this.var2 = var2; }
  }
  </code></pre>
  
  <p>would yield a JSON sample that could look like:</p>
  
  <pre><code>{
    "var1": "string1",
    "var2": "string2"
  }
  </code></pre>
  
  <p>any ideas? We could of course hand code that. Just looking to see if there is something already out there.</p>