Jackson 3rd Party Class With No Default Constructor

I'm trying to use Jackson to read/write my POJOs to/from Json. As of right now, I've got it configured and working for my classes, except for a 3rd party class. When trying to read in the Json I get the error:

org.codehaus.jackson.map.JsonMappingException: No suitable constructor found for type

After a few quick google searches, it appears that my class needs either a default constructor or to override the default constructor with annotations. Unfortunately, the class in which this is failing is from a 3rd party library and that class does not have a default constructor and I obviously cannot over-write the code.

So my question is, is there anything I can do about this or am I just out of luck?

Thanks.


You could make use of Jackson's Mix-Ins feature, coupled with the Creator feature. The Mix-Ins feature alleviates the need to annotate the original third-party code, and the Creator feature provides a mechanism for custom instance creation.

For yet more customization, it's not too involved to write a custom deserializer.