Description

Using the Hibernate Synchronizer editor, which binds to *.hbm by default, Hibernate persistance objects will be created and modified for you as you make changes to your mapping files.
The objects that will be synchronized include:

For the value objects, subclasses, components, and DAOs, the generated code will be placed in an abstract base class with an extension class created for you to put your code. The purpose of this is to allow re-synchronization without deleting any of the code you have added.

Options

Project Properties

You can decide whether you would like to automatically run the synchronization. You might turn this off if you want to just use the editor for the code assist functionality or if you prefer to manually run the synchronization process.

You also have the option to, at the project level, decide where your base objects will be created with three choices:

These same options are available for DAOs as well.

Manual Synchronization

Manual Synchronization

If you choose to use a different editor for your Hibernate files, you will not be able to use the auto-synchronize on save feature. You still, however, will be able to synchronize your files. Simply select select all of the Hibernate mapping files you wish to synchronize in the navigation window, right click and click Hibernate >> Synchronize Files.