Friday, February 17, 2012

Type was not included in the set of types which can be serialized by this SerializationPolicy or its Class object could not be loaded. For security purposes, this type will not be serialized.

While working on a GWT application incorporating a SuggestBox and a custom suggestion oracle class I got stung by the following error:

"Type 'custom suggestion class' was not included in the set of types which can be serialized by this SerializationPolicy or its Class object could not be loaded. For security purposes, this type will not be serialised."

The solution to my particular problem was to move the custom suggestion class into the client side package (it needs to be on the client side).


Decided to put a post up about this solution to the problem because it has a very faint web foot print, most other suggested fixes are about creating a empty constructor for your suggestion class.