Win a copy of Java Mock Exams (software) this week in the Programmer Certification (OCPJP) forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Java 5, ENUM and Hibernate

 
Angela Stempfel
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi all

i have some problems with the flexible enum solutiion described here:
http://hibernate.org/272.html
The following error occurs when calling the nullSafeGet method:



my method looks like that:



My Enum class:


And here the parts of my mapping file:



Some help appreciated! Other solutions with UserTypes and ENUM's are welcome as well.

Kind Regards
Angela
[ August 30, 2006: Message edited by: Angela Stempfel ]
 
Angela Stempfel
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i finally found the solution! the method fromInt must be defined as static!

angela
 
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!