I have the following json:

```
{"resourceWithType":
  {"parentId":0,
   "pluginId":0,
   "pluginName":"Platforms",
   "resourceId":10001,
   "resourceName":"snert",
   "typeId":10057,
   "typeName":"Mac OS X"
  }
}

```

And a class

```
public class ResourceWithType {

    String resourceName;
    int resourceId;
    String typeName;

```

with all the getters and setters and so on.

The above JSON was actually created via RESTeasy and the Jettison provider where the class was marked with `@XmlRootElement`.

When I try to deserialize the above JSON via

```
ObjectMapper mapper=new ObjectMapper();
ResourceWithType rwt = mapper.readValue(json,ResourceWithType.class);

```

It fails with 

```
06-13 11:07:55.360: WARN/System.err(26040): 
   org.codehaus.jackson.map.exc.UnrecognizedPropertyException: 
   Unrecognized field "resourceWithType" 
   (Class org.rhq.core.domain.rest.ResourceWithType), 
   not marked as ignorable

```

Which is sort of understandable.

How can I tell Jackson, that the embedded 'resourceWithType' is actually the class to deserialize into?

Other option would be to tell jettison not to include that type - how?