//serialize to XMI
String xmiStr = serialize(originalCas, null);
//deserialize into a CAS with no type system
CAS casWithNoTs = CasCreationUtils.createCas(new TypeSystemDescription_impl(),
new TypePriorities_impl(), new FsIndexDescription[0]);
XmiSerializationSharedData sharedData = new XmiSerializationSharedData();
deserialize(xmiStr, casWithNoTs, sharedData, true, -1);
// now reserialize including OutOfTypeSystem data
String xmiStr2 = serialize(casWithNoTs, sharedData);