• Post Reply Bookmark Topic Watch Topic
  • New Topic

EJB 3.0 cmp problem with Java interfaces  RSS feed

 
Paul Smiley
Ranch Hand
Posts: 245
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all. I'm a newbie at 3.0 so if something I write is unclear, please let me know and I'll try to clarify.

I'm writing a Pojo for an entity bean. I want this Pojo to implement an interface. I also need this Pojo to contain a List (or collection of some sort) of type {the interface}. I keep getting a JBoss deployment error:

[exec] State: FAILED
[exec] Reason: org.hibernate.MappingException: Could not determine type for: java.util.List, for columns: [org.hibernate.mapping.Column({the interface})]



Any ideas how I may write this to make it work (if it can)? At this point, I have no explicit annotations on the accessors for the List. Thanks!
Paul
[ November 08, 2006: Message edited by: Paul Smiley ]
 
Paul Smiley
Ranch Hand
Posts: 245
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
anyone?
 
Jaikiran Pai
Sheriff
Posts: 10447
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am new to EJB3 but going by the exception that you are seeing it seems that Hibernate is not able to recognize the InterfaceItem.
At this point, I have no explicit annotations on the accessors for the List.


In that case Hibernate should not have considered this as an mapped attribute. Can you post the entire stacktrace and the entire contents of the Entity.
 
Paul Smiley
Ranch Hand
Posts: 245
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you for your reply, Jaikiran. We decided the construct this in a different manner.
Paul
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!