title: How to map Json to Java classes when some variable names begin with a number?
body: <p>Recently I've been playing with a webservice that returns a <code>json</code> object like this</p>
  
  <pre><code>{
    "id": 88319,
    "dt": 1345284000,
    "name": "Benghazi",
    "coord": {
      "lat": 32.12,
      "lon": 20.07
    },
    "main": {
      "temp": 306.15,
      "pressure": 1013,
      "humidity": 44
    },
    "wind": {
      "speed": 1,
      "deg": -7
    },
    "clouds": {
      "all": 90
    },
    "rain": {
      "3h": 3
    }
  }
  </code></pre>
  
  <p>I have automatically generated Java classes mapping to that json data. The problem is I cannot generate a Java class with an attribute named <strong>3h</strong> (in Java as in many other languages variable identifiers cannot begin with a number). As a hack around I have redefined the attribute <strong>3h</strong> as <strong>h3</strong>, and whenever I receive a json response from the web service I replace the string "3h" by "h3". </p>
  
  <p>However, that approach is only appropriate for small projects. I would like to know if there is a more convenient approach to deal with this kind of situation.</p>
  
  <p>Notes: For this particular example I used an online tool that generated the java classes given a json example. In other situations I have used Jackson, and other frameworks. ¿Is the answer to this question framework dependent? To be more concrete, and having the future in mind, I would like to adhere to the json-schema specification </p>