ItemTypeDescriptor itd = getItemTypeDescriptor(item.getItemType());
if (itd.isContainedItem())
{
// Item is wrapped by a container class in its xml file
obj = new ItemContainer(item);
}
// Dirty hack:
// Castor doesn't support CDATA sections. So we write a dummy string and replace that
// dummy string for the actual CDATA-escaped string when writing the xml to the file.