title: (Jackson 1.9.2) Getting @JsonIgnore to work: deserialization with mixin annotations and polymorphic types
body: <p>I am trying to deserialize a JSON String like (extracted this bit to show the issue)</p>
  
  <pre><code>{
      "$type": "com.example.StringProperty",
      "value": "hello world",
      "name": "text",
      "readOnly": false
  }
  </code></pre>
  
  <p>into a hierarchy of classes that look like</p>
  
  <pre><code>public class Property
  {
      public String name;
      public int    type;
  
      Property(String pName, int pType) { name = pName; type = pType; }
  }
  
  public class StringProperty extends Property 
  {
      public String value;        
      StringProperty(String pName, String pValue) {
          super(pName, String);
          value = pValue;
      }       
  }
  </code></pre>
  
  <p>using the following mixin annotations</p>
  
  <pre><code>@JsonTypeInfo(use=JsonTypeInfo.Id.CLASS, include=JsonTypeInfo.As.PROPERTY, property="$type")
  abstract public class PropertyMixin
  {
      @JsonProperty
      public String name;
      //@JsonIgnore
      //public boolean readOnly;
      @JsonProperty
      public int type;
  
      PropertyMixin(@JsonProperty("name") String pName, @JsonProperty("type") int pType)
      {
      }
  }
  
  abstract public class StringPropertyMixin
  {
      @JsonProperty
      public String value;
      //@JsonIgnore
      //public boolean readOnly;
  
      @JsonCreator
      public StringPropertyMixin(@JsonProperty("name") String pName, @JsonProperty("value") String value)
      {
      }
  }
  </code></pre>
  
  <p>With Jackson 1.9.2, the error I am getting is</p>
  
  <p><code>Unrecognized field "readOnly" (Class com.example.StringProperty), not marked as ignorable</code></p>
  
  <p>I tried using <code>@JsonIgnore</code>, but that did not help (check the locations of the code I commented out to see how I tried it). I am probably missing something, but I think another set of eyes need to look at it and help me.</p>
  
  <p>This is how the deserialization environment looks like:</p>
  
  <pre><code>        objectMapper.setVisibilityChecker(objectMapper.getSerializationConfig().getDefaultVisibilityChecker()
                  .withFieldVisibility(JsonAutoDetect.Visibility.NONE)
                  .withGetterVisibility(JsonAutoDetect.Visibility.NONE)
                  .withSetterVisibility(JsonAutoDetect.Visibility.NONE)
                  .withCreatorVisibility(JsonAutoDetect.Visibility.NONE));
  
          MixinRegistrations module = new MixinRegistrations();
          objectMapper.registerModule(module);
  </code></pre>
  
  <p>and mixin module looks like</p>
  
  <pre><code>@Override
  public void setupModule(SetupContext context)
  {
      context.setMixInAnnotations(Property.class, PropertyMixin.class);
      context.setMixInAnnotations(StringProperty.class, StringPropertyMixin.class);
  }
  </code></pre>
  
  <p>I appreciate all the help. Thanks in advance.</p>
  
  <p>PS: I do not know if this makes a difference but the JSON is being generated by a library written in .Net Framework v4.</p>