Bug 280076 Make model loading plugable
Today our EMF usage is structured in a way that we can only load a model from XMI and inherit from EObjectImpl. This makes it impossible to leverage other EMF-Technologies (e.g. CDO). We should think about how we can restructure our code base to have possibility to support different model-storage technologies and different EObject-Implementations.
bundles/org.eclipse.e4.ui.workbench/src/org/eclipse/e4/workbench/ui/internal/ResourceHandler.java
resource = new E4XMIResource();
			MApplication theApp = loadDefaultModel(applicationDefinitionInstance);
			resource.getContents().add((EObject) theApp);
			resource.setURI(restoreLocation);
		}
		return resource;
	}
	private MApplication loadDefaultModel(URI defaultModelPath) {
		Resource resource = loadResource(defaultModelPath);
		MApplication app = (MApplication) resource.getContents().get(0);
		return app;
	}
	
	private Resource loadResource(URI uri) {
		Resource resource;
		try {
			resource = resourceSetImpl.getResource(uri, true);
		} catch (Exception e) {
			
			logger.error(e);
			resource = resourceSetImpl.getResource(uri, false);
		}
		return resource;
	}
	public void save() throws IOException {
		if (RESTORE_VIA_DELTAS) {
			try {
				Document document = (Document) reconciler.serialize();
				
				TransformerFactory tFactory = TransformerFactory.newInstance();