You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@uima.apache.org by gary underwood <un...@bellsouth.net> on 2020/04/09 20:01:07 UTC

Deserialization of Annotation containing Map

Hello all,
I have made a subclass of Annotation that contains a user defined Map object of String to Boolean. The class implements UimaSerializable.

It overrides _save_to_cas_data() which is called by XmiCasSerializer.serialize. It follows documentation from user guides for storing the keys and values of the Map as StringArray and BooleanArray respectively.  Stepping through the code it does run and the resulting xml file has the proper data in it from the map.

It also overrides _init_from_cas_data(). However, stepping through the code when usingXmiCasSerializer.deserialize, the method is never called and deserialization doesn’t work.

I do not know why _init_from_cas_data() is not called or how to make it get called during deserialization.

Thanks,
Gary
Clinacuity, Inc.