File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Object Relational Mapping and the fly likes Hibernate Xdoclet : how to mapping Enum in Java to Hibernate hbm.xml Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "Hibernate Xdoclet : how to mapping Enum in Java to Hibernate hbm.xml" Watch "Hibernate Xdoclet : how to mapping Enum in Java to Hibernate hbm.xml" New topic
Author

Hibernate Xdoclet : how to mapping Enum in Java to Hibernate hbm.xml

Jeffrey Hsu
Greenhorn

Joined: Aug 03, 2005
Posts: 1
Code:

[Rating.java]
public enum Rating {
Public, Normal, Private;
}

[Message.java]
public class Message {
private Rating rating;
...
/**
* @hibernate.property
* ??how to write??
*
*/
public Rating getRating() {
return rating;
}
...
}

thanks for your answer.
Jason Menard
Sheriff

Joined: Nov 09, 2000
Posts: 6450
I'm going to move this to the Object Relational Mapping forum which is more suitable for Hibernate questions.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Hibernate Xdoclet : how to mapping Enum in Java to Hibernate hbm.xml