|Re: Create a new model (instance) that conforms to my metamodel in Java class [message #1685236 is a reply to message #1685198]
||Wed, 18 March 2015 19:18
| Edoaurd Batot
Registered: March 2015
Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE;
Map<String, Object> m = reg.getExtensionToFactoryMap();
m.put("xmi", new XMIResourceFactoryImpl());
m.put("ecore", new XMIResourceFactoryImpl());
ResourceSet resourceSet = new ResourceSetImpl();
[b]Ramified mm = new Ramified(resourceSet);
Resource resource = (Resource) resourceSet.createResource(URI.createFileURI("models/MyInstance.xmi"));
Registering the package explicitly from the "instance" I've built from the .ecore (and more precisly, its root EPackage).
This looks like what changed this day in a beautyfull one !
Thanks a lot Ed for your support !
[Updated on: Wed, 18 March 2015 19:18]
Report message to a moderator
Powered by FUDForum
. Page generated in 0.02281 seconds