Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 311178 - NullPointerException within EContainerFeatureIDUserType on commit
Summary: NullPointerException within EContainerFeatureIDUserType on commit
Status: RESOLVED FIXED
Alias: None
Product: EMF
Classification: Modeling
Component: Teneo (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Martin Taal CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-04-30 10:02 EDT by ndose CLA
Modified: 2010-05-02 10:44 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description ndose CLA 2010-04-30 10:02:49 EDT
Build Identifier: M20100211-1343

Having trouble with null values at line 82 in org.eclipse.emf.teneo.hibernate.mapping.econtainer.EContainerFeatureIDUserType (v 1.4 2009/12/04 15:07:02 mtaal ):
   return ((EContainerFeatureIDHolder) value).convertToString();

Why 'value' is null in my exact case I can't tell, I've inherited the EMF model from a colleague and am doing very rudimentary stuff with it (see steps to reproduce below) - but that's another question.

The other attribute types all make an explicit check against null, e.g. IntegerType/StringType:

if (value==null) {
  return null;
}
else...



Versions: org.eclipse.emf.teneo.hibernate_1.1.2.v201004282142.jar,   org.eclipse.emf.teneo_1.1.2.v201004282141.jar, org.eclipse.emf.teneo.hibernate.mapper_1.1.2.v201004282142.jar


Reproducible: Always

Steps to Reproduce:
1. Open a hibernate session and transaction
2. Create EMF object via factory
3. Set some attribute values on object
4. session.save(emfObject)
5. session.getTransaction().commit()
Comment 1 Martin Taal CLA 2010-05-02 10:44:48 EDT
I did a new build for Teneo which should solve this. Note that Teneo has a new download site and that there is also an update site for its dependencies:
http://wiki.eclipse.org/Teneo/Hibernate/Download_and_Install