SampledFieldGeometry sfg = (SampledFieldGeometry) contextObject;
if (elementName.equals(SpatialConstants.listOfSampledVolumes)){
ListOf<SampledVolume> listOfSampledVolumes = sfg.getListOfSampledVolumes();
return listOfSampledVolumes;
} else if (elementName.equals(SpatialConstants.sampledField)){
SampledField sf = new SampledField();
sfg.setSampledField(sf);
return sf;
}
} else if (contextObject instanceof SampledField) {
SampledField sf = (SampledField) contextObject;
if (elementName.equals(SpatialConstants.imageData)){
ImageData im = new ImageData();
sf.setImageData(im);
return im;
}
} else if (contextObject instanceof CSGeometry) {
CSGeometry csg = (CSGeometry) contextObject;
if (elementName.equals(SpatialConstants.listOfCSGObjects)){