[
http://opensource.atlassian.com/projects/hibernate/browse/HHH-5533?page=c...
]
Kariem Hussein updated HHH-5533:
--------------------------------
Attachment: docbook-en-modules-configuration.diff
Attaching patch to resolve the problems outlined in the description. The patch is agains
r20306 of {{/core/trunk/entitymanager/src/main/docbook/en/modules/configuration.xml}}
Entity Manager documentation: example at the end of the bootstrapping
section is invalid
----------------------------------------------------------------------------------------
Key: HHH-5533
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-5533
Project: Hibernate Core
Issue Type: Patch
Components: documentation, entity-manager
Reporter: Kariem Hussein
Attachments: docbook-en-modules-configuration.diff
The example at the end of the [bootstrapping section of the entity manager
documentation|http://docs.jboss.org/hibernate/stable/entitymanager/refere...]
contains syntax errors and invalid method calls.
*Current version*
{code}
Ejb3Configuration cfg = new Ejb3Configuration();
EntityManagerFactory emf =
cfg.addProperties( properties ) //add some properties
.setInterceptor( myInterceptorImpl ) // set an interceptor
.addAnnotatedClass( MyAnnotatedClass.class ) //add a class to be mapped
.addClass( NonAnnotatedClass.class ) //add an hbm.xml file using the Hibernate
convention
.addRerousce( "mypath/MyOtherCLass.hbm.xml ) //add an hbm.xml file
.addRerousce( "mypath/orm.xml ) //add an EJB3 deployment descriptor
.configure("/mypath/hibernate.cfg.xml") //add a regular hibernate.cfg.xml
.buildEntityManagerFactory(); //Create the entity manager factory
{code}
*Problems*
- {{addRerousce}} instead of {{addResource}}
- strings are not properly closed in lines 7 and 8
- formatting is not consistent (capitalization, spacing)
- comments are not aligned
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira