title: How do you properly bind a list of objects into a Grails command?
body: <p>I'm trying to figure out how to deserialize and validate nested objects in JSON request into a Grails 2.1.1 command object.</p>
  
  <p>Currently I have a command object in my controller that has a few basic properties and then list of domain objects,</p>
  
  <pre><code>protected static class CustomCommand {
      String name
      String description
      List&lt;DomainObject&gt; objs
  }
  </code></pre>
  
  <p>And a JSON body to my POST request,</p>
  
  <pre><code>{
      name: 'test name',
      description: 'test description',
      objs: [
          {
              name: 'test sub object',
              description: 'test description'
          }
      ]
  }
  </code></pre>
  
  <p>I'm seeing the command object created with an empty array. <strong>Any idea how I can get the sub objects my in JSON body to deserialize into the command object and then validate them?</strong></p>
  
  <p>Previously I've worked around this by manually creating an object from the parameter map and validating that directly, but that feels like a workaround that isn't taking advantage of everything Grails offers.</p>