title: How to convert a JSON request into a list of specific format n spring?
body: <p>I have a request JSON list like this:</p>
  <pre><code>[
   {
    Id: 0,
    values: [a, b, c, d]
   },
   {
    Id: 1,
    values: [1, 2, 3, 4]
   },
   .
   .
   .
  ]
  </code></pre>
  <p>How do I convert this to a list like this:</p>
  <pre><code>[
   {
    Name: a,
    Count: 1
   },
   {
    Name: b,
    Count: 2
   }
   {
    Name: c,
    Count: 3
   }
   {
    Name: d,
    Count: 4
   }
  ]
  </code></pre>
  <p>I have a dto class consisting of name and count attributes.</p>