[resolved]
//-- Retrieve the CDATA content
CodeType code = mymodel.getCode();
FeatureMap map = code.getMixed();
if(map.size() > 0){
// Display CDATA
System.out.println(map.getValue(0));
}
//-- Set the CDATA content
String newCDATAValue = '......';
CodeType code = DevFactory.eINSTANCE.createCodeType();
FeatureMap m = code.getMixed();
m.add(FeatureMapUtil.createCDATAEntry(newCDATAValue));
Command setCodeType = SetCommand.create(getEditingDomain(), mymodel, DevPackage.Literals.MODELTYPE__CODE, c);
getEditingDomain().getCommandStack().execute(setCodeType);
[Updated on: Mon, 09 August 2010 08:43]
Report message to a moderator