Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » Re: [Teneo] Need ClassMetadata but it's not present
Re: [Teneo] Need ClassMetadata but it's not present [message #687412] Wed, 08 June 2011 07:58
Martin Taal is currently offline Martin TaalFriend
Messages: 5468
Registered: July 2009
Senior Member
Yes getClassMetaData is supposed to work, the getSessionFactory returns a plain/standard Hibernate SessionFactory
implementation (no Teneo overrides there). But I think that the 'problem' is in the parameter passed to the
getClassMetaData, maybe Vaadin uses the classname or the class while Teneo maps using entity names. I guess that is the
thing to check.

Btw, Teneo questions are answered on the main EMF newsgroup, which I added as a cc.

And if you are using EMF in a web server environment (so not RCP) then it can make sense to checkout the Texo projects,
it generates real pojo's (no EMF compile dependencies) while still supporting many/most EMF concepts (XML serialization,
featuremaps, etc.).

gr. Martin

On 06/07/2011 11:36 PM, wrote:
> I'm trying to get a Vaadin Hibernate Container (HbnContainer) to work with my Teneo based datastore. There is an
> HbnContainer add-on class supplied by the Vaadin folks which I'm trying to use with one of the Teneo model managed
> classes I have. The HbnContainer makes extensive use of ClassMetadata from the SessionFactory. In particular
> HbnContainer uses the getPropertyType, getIdentifier, getIdentifierType, getIdentifierProperty methods.
> Unfortunately my instantiated HbDataStore.getSessionFactory().getClassMetadata() returns null. The SessionFactory()
> seems to work fine for all my other "normal" uses (mainly getting Session).
> My Teneo model is being loaded from a .ecorediag -> .ecore -> .genmodel file.
> So my questions are:
> 1) Is HbDataStore.getSessionFactory().getClassMetadata() suppose to return a real ClassMetadata or is this not supported
> with Teneo?
> 2) If getClassMetadata() is suppose to work, any suggestions on what I'm missing?
> 3) If getClassMetadata() is not supported, any suggestions for getting similar data to getPropertyType, getIdentifier,
> getIdentifierType, getIdentifierProperty?
> URL for HbnContainer:


With Regards, Martin Taal

Office: Hardwareweg 4, 3821 BV Amersfoort
Postal: Nassaulaan 7, 3941 EC Doorn
The Netherlands
Cell: +31 (0)6 288 48 943
Tel: +31 (0)84 420 2397
Fax: +31 (0)84 225 9307
Mail: -
Web: -
Previous Topic:Re: [Teneo] Need ClassMetadata but it's not present
Next Topic:Parsing a model (xmi) to get tree view?
Goto Forum:

Current Time: Tue Sep 22 02:40:17 GMT 2020

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

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

Back to the top