This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Blog around the Campfire and the fly likes Simple Hibernate Container Example Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Other » Blog around the Campfire
Bookmark "Simple Hibernate Container Example" Watch "Simple Hibernate Container Example" New topic
Author

Simple Hibernate Container Example

Christopher Rygaard
Ranch Hand

Joined: Feb 22, 2014
Posts: 42
    
    3
Simple Container Example

This is the simplest stand-alone Hibernate container example I could cook up.

The interesting parts are the annotation on Contained._container and Container._children.

Notice: This is provided with no warranty whatsoever. Use at your own risk.

This is the contained class:

This is the container class:

This is an example of how to use a container in Hibernate:
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: Simple Hibernate Container Example
 
Similar Threads
Simple Hibernate Eager Loading Example
Simple Hibernate Example with Inner Classes
Simple Hibernate Lazy Loading Example
Simple Hibernate Example with Final Classes and Final Methods
Simple Hibernate Cascade Save Example