title: convert key's value as a key in json using GSON
body: <p>I am generating following JSON using GSON library </p>
  
  <pre><code>[
    {
      "name": "Mobile Number",
      "value": "234567891"
    },
    {
      "name": "Controller Number",
      "value": "I1500001"
    },
    {
      "name": "Unit Type",
      "value": "2"
    },
    {
      "name": "Operator",
      "value": "32"
    },
    {
      "name": "Data Length",
      "value": "0"
    },
    {
      "name": "Software Version",
      "value": "32"
    },
    {
      "name": "Mode",
      "value": "6"
    }
  ]
  </code></pre>
  
  <p>My class has two fields as follows </p>
  
  <pre><code>public class IDUData {
  
          @SerializedName("name")
          private String name;
          @SerializedName("value")
          private String value;
          public String getName() {
              return name;
          }
          public void setName(String name) {
              this.name = name;
          }
          public String getValue() {
              return value;
          }
          public void setValue(String value) {
              this.value = value;
          }
      }
  </code></pre>
  
  <p>now what i want to do is to generate JSON in following forma.i want my <code>name</code> key field's value to be a key. the reason why i am using this approach is in future if new name key is added , my expected json will automatically has a key.</p>
  
  <pre><code>[
    {
      "Mobile Number": "234567891"
    },
    {
      "Controller Number": "I1500001"
    },
    {
      "Unit Type": "2"
    },
    {
      "Operator": "32"
    },
    {
      "Data Length": "0"
    },
    {
      "Software Version": "32"
    },
    {
      "Mode": "6"
    }
  ]
  </code></pre>