title: Jackson map JSON containing different items for same object
body: <p>I've got the follwoing JSON structure with the corresponding DTOs in Java:  </p>
  
  <pre><code>{
    "kind": "object 1",
    "selfLink": "some_link",
    "items": [
      {
        "kind": "subkind 1",
        "name": "server 1",
  
        "anotherObject": {
          "link": "some_link",
          "isSubcollection": true,
          "items": [
            {
              "att 1": "value",
              "att2": "value",
              "att3": "value"
            },
            {
              "att5": "value" ,
              "att6": "value" ,
              "att7": "value" ,
              "att8": "value"
            }
          ]
        }
      }
    ]
  }
  </code></pre>
  
  <p>Now I want to map this into corresponding <code>DTO</code>s using <code>Jackson</code>. Using the <code>@JsonIgnoreUnknown</code> annotation, this works fine. The problem is within the <code>items</code> array: How can I map different classes from the same JSON list in Jackson? Of course I could create a huge class containing both's attributes, but that would not be my way of choice.<br>
  I hope you can help me.</p>