title: Create map or object with nested fields from properties file in Java
body: <p>I need to create JSON from Properties file with nested fields?
  For example, we have the following properties file:</p>
  
  <pre><code>student.name="John"
  student.exam.math=5
  teacher.skills=10
  </code></pre>
  
  <p>And I need the following JSON file on output:</p>
  
  <pre><code>Properties : {
      student : {
          name : "John",
          exam : {
              math : 5
          }
      },
      teacher : {
         skills : 10
      }
  }
  </code></pre>
  
  <p>JSON code can be produced with FLEX-JSON Serializer or GSON libraries and this is not a problem. The main problem is to parse properties and produce Java Object or Map with nested properties. Is there any library allowing to do that? Thanks!</p>