Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc)  » [Teneo] Persisting an Ecore Model
[Teneo] Persisting an Ecore Model [message #606776] Thu, 24 May 2007 06:19
Ian Bull is currently offline Ian BullFriend
Messages: 145
Registered: July 2009
Senior Member
I have been trying to persist a bunch of data (each to its own database)
and the corresponding Ecore model to which each of the datasets conforms
(each Ecore model would be persisted to its own database). At some
point in the future I plan on loading one of the datasets, but before I
can load the dataset, I need to load the ecore model. So the algorithm
is basically:

determine what dataset I need
create a hbds with EcorePackage and XMLTypePackage as the ePackages
do query("from ecore_EObject as EObject where dtype='EPackage'");
create a hbds with the result of the query as the ePackage
query the new hbds on the instance data

However, when I loaded the ePACKAGE I received a number of errors
because it seems that the eTypes are not persisted. In order to get
this to work, I had to add the following lines when I persisted the
models, and again, when I load them back:

EcorePackage.eINSTANCE.getETypedElement().getEStructuralFeat ure(EcorePackage.ETYPED_ELEMENT__ETYPE).setVolatile(false);
EcorePackage.eINSTANCE.getEClass().getEStructuralFeature(Eco rePackage.ECLASS__INSTANCE_CLASS_NAME).setVolatile(false);

I am posting this here in case others have similar problems.

Martin, Ed, does this make sense to you guys?

cheers,
ian
Previous Topic:[Teneo] how to get e_id?
Next Topic:[Teneo] Persisting an Ecore Model
Goto Forum:
  


Current Time: Sun May 05 13:58:11 GMT 2024

Powered by FUDForum. Page generated in 0.02661 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top