i am a newbie too but i can try answering these questions.
* There will be a main Hibernate application whose work is only to give you a sessionfactory. You can put this application in a seperate package say, com.srh.hibernate.
Then in your com.srh.ta package you call the main Hibernate application to open a session, do what you want to do, finish your work and then close the session.
* its upto you but i think persisting only current employee is a good idea.
* Hibernate is much more than Persistence.
|