Document document = ModelPersistence.saveModel(myToCopy);
Element rootElement = document.getRootElement();
rootElement.setAttribute(ModelPersistence.MODEL_UID, getSModelReference().toString());
SModel result = ModelPersistence.readModel(document, NameUtil.shortNameFromLongName(myToCopy.getLongName()), myToCopy.getStereotype());
result.setLoading(true);
<BUG>return new ModelLoadResult(result,ModelLoadingState.FULLY_LOADED);
</BUG>
}
@Override
public Set<IModule> getModules() {

Document document = ModelPersistence.saveModel(myToCopy);
Element rootElement = document.getRootElement();
rootElement.setAttribute(ModelPersistence.MODEL_UID, getSModelReference().toString());
SModel result = ModelPersistence.readModel(document, NameUtil.shortNameFromLongName(myToCopy.getLongName()), myToCopy.getStereotype());
result.setLoading(true);
return new ModelLoadResult(result, ModelLoadingState.FULLY_LOADED);
}
@Override
public Set<IModule> getModules() {
