[jboss-cvs] JBossAS SVN: r97594 - in projects/docs/enterprise: EWP_5.0/Hibernate/Hibernate_Core/en-US and 1 other directory.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Wed Dec 9 02:01:21 EST 2009


Author: laubai
Date: 2009-12-09 02:01:20 -0500 (Wed, 09 Dec 2009)
New Revision: 97594

Modified:
   projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/basic_mapping.xml
   projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/batch.xml
   projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/events.xml
   projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/performance.xml
   projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/persistent_classes.xml
   projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/query_criteria.xml
   projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/query_hql.xml
   projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/query_sql.xml
   projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/session_api.xml
   projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/transactions.xml
   projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/tutorial.xml
   projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/batch.xml
   projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/events.xml
   projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/performance.xml
   projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/persistent_classes.xml
   projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/query_criteria.xml
   projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/query_sql.xml
   projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/tutorial.xml
Log:
Added changes for JBPAPP-2965 to EWP_5.0 and 5.0 tags.

Modified: projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/basic_mapping.xml
===================================================================
--- projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/basic_mapping.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/basic_mapping.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -48,8 +48,7 @@
             Here is an example mapping:
         </para>
 
-     <!--     <programlisting id="mapping-declaration-ex1" revision="1"> -->
-        <programlisting><![CDATA[<?xml version="1.0"?>
+        <programlisting id="mapping-declaration-ex1" revision="1"><![CDATA[<?xml version="1.0"?>
 <!DOCTYPE hibernate-mapping PUBLIC
       "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
           "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
@@ -167,10 +166,21 @@
                 <para>
                     The following is an example of utilizing user namespacing:
                 </para>
-                 <programlisting language="XML" role="XML">
-<xi:include parse="text" href="extras/namespacing.xml_sample" xmlns:xi="http://www.w3.org/2001/XInclude" />
-</programlisting> 
-        
+                <programlisting><![CDATA[<?xml version="1.0"?>
+<!DOCTYPE hibernate-mapping PUBLIC
+        "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
+        "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd" [
+    <!ENTITY types SYSTEM "classpath://your/domain/types.xml">
+]>
+
+<hibernate-mapping package="your.domain">
+    <class name="MyEntity">
+        <id name="id" type="my-custom-id-type">
+            ...
+        </id>
+    <class>
+    &types;
+</hibernate-mapping>]]></programlisting>
                 <para>
                     Where <literal>types.xml</literal> is a resource in the <literal>your.domain</literal>
                     package and contains a custom <xref linkend="mapping-types-custom" />.
@@ -453,7 +463,7 @@
                     </callout>
                     <callout arearefs="class19">
                         <para>
-                            <literal>rowid</literal> (optional): Hibernate can use ROWIDs on databases. On Oracle, for example, Hibernate can use the 				    <literal>rowid</literal> extra
+                            <literal>rowid</literal> (optional): Hibernate can use ROWIDs on databases. On Oracle, for example, Hibernate can use the                   <literal>rowid</literal> extra
                             column for fast updates once this option has been set to <literal>rowid</literal>. A ROWID
                             is an implementation detail and represents the physical location of a stored tuple.
                         </para>
@@ -559,7 +569,7 @@
             <para>
                 It is <emphasis>strongly</emphasis> recommended that you use version/timestamp
                 columns for optimistic locking with Hibernate.
-		This strategy optimizes performance and correctly handles modifications
+        This strategy optimizes performance and correctly handles modifications
                 made to detached instances (i.e. when <literal>Session.merge()</literal> is used).
             </para>
 
@@ -690,7 +700,7 @@
                     All generators implement the interface <literal>org.hibernate.id.IdentifierGenerator</literal>.
                     This is a very simple interface. Some applications can choose to provide their own specialized
                     implementations, however, Hibernate provides a range of built-in implementations. The shortcut
-		    names for the built-in generators are as follows: </para>
+            names for the built-in generators are as follows: </para>
 
                     <variablelist>
                         <varlistentry>
@@ -953,7 +963,7 @@
                 incrementing values, depending on the capabilities of the dialect being used.  The difference between this
                 and <literal>native</literal> is that table-based and sequence-based storage have the same exact
                 semantic. In fact, sequences are exactly what Hibernate tries to emulate with its table-based
-		generators.  This generator has a number of configuration parameters:</para>
+        generators.  This generator has a number of configuration parameters:</para>
                 <itemizedlist spacing="compact">
                     <listitem>
                         <para>
@@ -1003,7 +1013,7 @@
                 as a re-implementation of <literal>org.hibernate.id.MultipleHiLoPerTableGenerator</literal> that utilizes the
                 notion of pluggable optimizers.  Essentially this generator defines a table capable of holding
                 a number of different increment values simultaneously by using multiple distinctly keyed rows.  This
-		generator has a number of configuration parameters:</para>
+        generator has a number of configuration parameters:</para>
                 <itemizedlist spacing="compact">
                     <listitem>
                         <para>
@@ -1387,7 +1397,7 @@
 
             <para>
                 A version or timestamp property should never be null for a detached instance.                
-		Hibernate will detect any instance with a null version or timestamp as transient,
+        Hibernate will detect any instance with a null version or timestamp as transient,
                 irrespective of what other <literal>unsaved-value</literal> strategies are specified.
                 <emphasis>Declaring a nullable version or timestamp property is an easy way to avoid
                 problems with transitive reattachment in Hibernate. It is especially useful for people
@@ -1476,15 +1486,15 @@
 
             
        <note>
-		<title>Note</title>
-		<para>
-		<literal>&lt;Timestamp&gt;</literal> is equivalent to
+        <title>Note</title>
+        <para>
+        <literal>&lt;Timestamp&gt;</literal> is equivalent to
                 <literal>&lt;version type="timestamp"&gt;</literal>.  And
                  <literal>&lt;timestamp source="db"&gt;</literal> is equivalent to
                 <literal>&lt;version type="dbtimestamp"&gt;</literal>
-		</para>
-	</note>            
-		
+        </para>
+    </note>            
+        
         </section>
 
 
@@ -1677,7 +1687,7 @@
             <para>
                 You can reference the entity table by not declaring an alias on
                 a particular column. This would be <literal>customerId</literal> in the given example. You can also use 
-		the nested <literal>&lt;formula&gt;</literal> mapping element
+        the nested <literal>&lt;formula&gt;</literal> mapping element
                 if you do not want to use the attribute.
             </para>
 
@@ -1889,7 +1899,7 @@
             </para>
 
             <para>
-            	If the referenced unique key is the property of a component, you can specify a property path:
+                If the referenced unique key is the property of a component, you can specify a property path:
             </para>
 
            <programlisting><![CDATA[<many-to-one name="owner" property-ref="identity.ssn" column="OWNER_SSN"/>]]></programlisting>
@@ -2578,7 +2588,7 @@
 
         </section>
 
-   	<section id="mapping-declaration-join" revision="3">
+    <section id="mapping-declaration-join" revision="3">
             <title>Join</title>
 
             <para>
@@ -2953,7 +2963,7 @@
 
             <para>
                 In relation to the persistence service, Java language-level objects are classified 
-		into two groups:
+        into two groups:
             </para>
 
             <para>
@@ -3314,12 +3324,12 @@
     </section>
 
 
-   	<section id="mapping-alternatives">
-   	<title>Metadata alternatives</title>
+    <section id="mapping-alternatives">
+    <title>Metadata alternatives</title>
 
-   	<para>
-   	    XML does not suit all users so there are some alternative ways to define O/R mapping metadata in Hibernate.
-   	</para>
+    <para>
+        XML does not suit all users so there are some alternative ways to define O/R mapping metadata in Hibernate.
+    </para>
 
     <section id="mapping-xdoclet">
         <title>Using XDoclet markup</title>
@@ -3343,7 +3353,7 @@
     private Long id; // identifier
     private Date birthdate;
     private Cat mother;
-    private Set kittens
+    private Set kittens;
     private Color color;
     private char sex;
     private float weight;
@@ -3460,10 +3470,10 @@
             This is an example of a POJO class annotated as an EJB entity bean:
         </para>
 
-        <programlisting><![CDATA[@Entity(access = AccessType.FIELD)
+        <programlisting><![CDATA[@Entity
 public class Customer implements Serializable {
 
-    @Id;
+    @Id
     Long id;
 
     String firstName;
@@ -3483,14 +3493,6 @@
     // Getter/setter and business methods
 }]]></programlisting>
 
-        <note>
-	<title>Note</title>
-	<para>
-            Support for JDK 5.0 Annotations (and JSR-220) is currently under development. 
-            Please refer to the Hibernate Annotations module for more details.
-        </para>
-	</note>
-
     </section>
     </section>
 
@@ -3512,22 +3514,22 @@
             <xref linkend="mapping-declaration-property" />, can be marked as
             generated.
         </para>
-	    <para>
-		    <literal>never</literal> (the default): the given property value
-		    is not generated within the database.
-	    </para>
-	    <para>
-		    <literal>insert</literal>: the given property value is generated on
-		    insert, but is not regenerated on subsequent updates.  Properties like created-date
-		    fall into this category.  Even though
-		    <xref linkend="mapping-declaration-version" /> and
-		    <xref linkend="mapping-declaration-timestamp" /> properties can
-		    be marked as generated, this option is not available.
-	    </para>
-	    <para>
-		    <literal>always</literal>: the property value is generated both
-		    on insert and on update.
-	    </para>
+        <para>
+            <literal>never</literal> (the default): the given property value
+            is not generated within the database.
+        </para>
+        <para>
+            <literal>insert</literal>: the given property value is generated on
+            insert, but is not regenerated on subsequent updates.  Properties like created-date
+            fall into this category.  Even though
+            <xref linkend="mapping-declaration-version" /> and
+            <xref linkend="mapping-declaration-timestamp" /> properties can
+            be marked as generated, this option is not available.
+        </para>
+        <para>
+            <literal>always</literal>: the property value is generated both
+            on insert and on update.
+        </para>
     </section>
 
     <section id="mapping-database-object">
@@ -3576,5 +3578,4 @@
     </database-object>
 </hibernate-mapping>]]></programlisting>
     </section>
-</chapter>
-
+</chapter>
\ No newline at end of file

Modified: projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/batch.xml
===================================================================
--- projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/batch.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/batch.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -46,14 +46,14 @@
         This would fall over with an <literal>OutOfMemoryException</literal> somewhere 
         around the 50,000th row. That is because Hibernate caches all the newly inserted 
         <literal>Customer</literal> instances in the session-level cache. In this chapter 
-	we will show you how to avoid this problem.
+    we will show you how to avoid this problem.
     </para>
 
     <para>
         
         If you are undertaking batch processing you will need to enable the use of
         JDBC batching.  This is absolutely essential if you want to achieve optimal performance.
-	Set the JDBC batch size to a reasonable number (10-50, for example):
+    Set the JDBC batch size to a reasonable number (10-50, for example):
     </para>
     
 <programlisting><![CDATA[hibernate.jdbc.batch_size 20]]></programlisting>
@@ -146,7 +146,7 @@
             using a stateless session never cascade to associated instances. Collections 
             are ignored by a stateless session. Operations performed via a stateless session 
             bypass Hibernate's event model and interceptors. Due to the lack of a first-level cache, 
-	    Stateless sessions are vulnerable to data aliasing effects. A stateless
+        Stateless sessions are vulnerable to data aliasing effects. A stateless
             session is a lower-level abstraction that is much closer to the underlying JDBC.
         </para>
         
@@ -194,13 +194,13 @@
             Hibernate Query Language (<xref linkend="queryhql" />).
         </para>
 
-	    <para>
+        <para>
             The pseudo-syntax for <literal>UPDATE</literal> and <literal>DELETE</literal> statements
             is: <literal>( UPDATE | DELETE ) FROM? EntityName (WHERE where_conditions)?</literal>.  
-	    </para>
+        </para>
 
-	<para>
-	Some points to note:
+    <para>
+    Some points to note:
         </para>
 
         <itemizedlist spacing="compact">
@@ -220,8 +220,8 @@
             <listitem>
                 <para>
                     No <xref linkend="queryhql-joins-forms" />, either implicit or explicit,
-	                can be specified in a bulk HQL query.  Sub-queries can be used in the where-clause, where
-	                the subqueries themselves may contain joins.
+                    can be specified in a bulk HQL query.  Sub-queries can be used in the where-clause, where
+                    the subqueries themselves may contain joins.
                 </para>
             </listitem>
             <listitem>
@@ -242,7 +242,7 @@
 
 String hqlUpdate = "update Customer c set c.name = :newName where c.name = :oldName";
 // or String hqlUpdate = "update Customer set name = :newName where name = :oldName";
-int updatedEntities = s.createQuery( hqlUpdate )
+int updatedEntities = session.createQuery( hqlUpdate )
         .setString( "newName", newName )
         .setString( "oldName", oldName )
         .executeUpdate();
@@ -262,7 +262,7 @@
 <programlisting><![CDATA[Session session = sessionFactory.openSession();
 Transaction tx = session.beginTransaction();
 String hqlVersionedUpdate = "update versioned Customer set name = :newName where name = :oldName";
-int updatedEntities = s.createQuery( hqlUpdate )
+int updatedEntities = session.createQuery( hqlVersionedUpdate )
         .setString( "newName", newName )
         .setString( "oldName", oldName )
         .executeUpdate();
@@ -284,7 +284,7 @@
 
 String hqlDelete = "delete Customer c where c.name = :oldName";
 // or String hqlDelete = "delete Customer where name = :oldName";
-int deletedEntities = s.createQuery( hqlDelete )
+int deletedEntities = session.createQuery( hqlDelete )
         .setString( "oldName", oldName )
         .executeUpdate();
 tx.commit();
@@ -367,11 +367,11 @@
 Transaction tx = session.beginTransaction();
 
 String hqlInsert = "insert into DelinquentAccount (id, name) select c.id, c.name from Customer c where ...";
-int createdEntities = s.createQuery( hqlInsert )
+int createdEntities = session.createQuery( hqlInsert )
         .executeUpdate();
 tx.commit();
 session.close();]]></programlisting>
 
     </section>
 
-</chapter>
+</chapter>
\ No newline at end of file

Modified: projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/events.xml
===================================================================
--- projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/events.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/events.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -127,7 +127,7 @@
 
     public void afterTransactionCompletion(Transaction tx) {
         if ( tx.wasCommitted() ) {
-            System.out.println("Creations: " + creates + ", Updates: " + updates, "Loads: " + loads);
+            System.out.println("Creations: " + creates + ", Updates: " + updates + "Loads: " + loads);
         }
         updates=0;
         creates=0;
@@ -206,7 +206,7 @@
     public void onLoad(LoadEvent event, LoadEventListener.LoadType loadType)
             throws HibernateException {
         if ( !MySecurity.isAuthorized( event.getEntityClassName(), event.getEntityId() ) ) {
-            throw MySecurityException("Unauthorized access");
+            throw new MySecurityException("Unauthorized access");
         }
     }
 }]]></programlisting>
@@ -232,7 +232,7 @@
 
         <programlisting><![CDATA[Configuration cfg = new Configuration();
 LoadEventListener[] stack = { new MyLoadListener(), new DefaultLoadEventListener() };
-cfg.EventListeners().setLoadEventListeners(stack);]]></programlisting>
+cfg.getEventListeners().setLoadEventListeners(stack);]]></programlisting>
 
         <para>
             Listeners registered declaratively cannot share instances. If the same class name is
@@ -288,5 +288,4 @@
        
     </section>
 
-</chapter>
-
+</chapter>
\ No newline at end of file

Modified: projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/performance.xml
===================================================================
--- projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/performance.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/performance.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -28,7 +28,7 @@
 <chapter id="performance">
     <title>Improving performance</title>
 
-    <section id="performance-fetching" revision="2">
+    <sect1 id="performance-fetching" revision="2">
         <title>Fetching strategies</title>
 
         <para>
@@ -139,7 +139,7 @@
             in any detached instance of a particular class.
         </para>
  
-        <section id="performance-fetching-lazy">
+        <sect2 id="performance-fetching-lazy">
             <title>Working with lazy associations</title>
             
             <para>
@@ -198,9 +198,9 @@
                 collections.
             </para>
         
-        </section>
+        </sect2>
         
-        <section id="performance-fetching-custom" revision="4">
+        <sect2 id="performance-fetching-custom" revision="4">
             <title>Tuning fetch strategies</title>
             
             <para>
@@ -278,9 +278,9 @@
                 second-level cache.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="performance-fetching-proxies" revision="2">
+        <sect2 id="performance-fetching-proxies" revision="2">
             <title>Single-ended association proxies</title>
 
             <para>
@@ -359,8 +359,8 @@
                 These problems are all due to fundamental limitations in Java's single inheritance model.
                 To avoid these problems your persistent classes must each implement an interface
                 that declares its business methods. You should specify these interfaces in the mapping file where 
-		<literal>CatImpl</literal> implements the interface <literal>Cat</literal> and <literal>DomesticCatImpl</literal>
-	        implements the interface <literal>DomesticCat</literal>. For example: 
+        <literal>CatImpl</literal> implements the interface <literal>Cat</literal> and <literal>DomesticCatImpl</literal>
+            implements the interface <literal>DomesticCat</literal>. For example: 
             </para>
 
             <programlisting><![CDATA[<class name="CatImpl" proxy="Cat">
@@ -380,13 +380,13 @@
 Cat fritz = (Cat) iter.next();]]></programlisting>
 
             
-	    <note><title>Note</title>
-	    <para>
-		<literal>list()</literal> does not usually return proxies.
-	    </para>
-	    </note>
-	    
-	     <para>
+        <note><title>Note</title>
+        <para>
+        <literal>list()</literal> does not usually return proxies.
+        </para>
+        </note>
+        
+         <para>
                 Relationships are also lazily initialized. This means you must declare any properties to be of
                 type <literal>Cat</literal>, not <literal>CatImpl</literal>.
             </para>
@@ -427,9 +427,9 @@
                 will result in immediate proxy initialization.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="performance-fetching-initialization" revision="1">
+        <sect2 id="performance-fetching-initialization" revision="1">
             <title>Initializing collections and proxies</title>
 
             <para>
@@ -521,9 +521,9 @@
 
             <programlisting><![CDATA[s.createFilter( lazyCollection, "").setFirstResult(0).setMaxResults(10).list();]]></programlisting>
 
-        </section>
+        </sect2>
 
-        <section id="performance-fetching-batch">
+        <sect2 id="performance-fetching-batch">
             <title>Using batch fetching</title>
 
             <para>
@@ -575,9 +575,9 @@
                 <emphasis>materialized path</emphasis> might be a better option for read-mostly trees.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="performance-fetching-subselect">
+        <sect2 id="performance-fetching-subselect">
             <title>Using subselect fetching</title>
 
             <para>
@@ -588,9 +588,9 @@
             
             <!-- TODO: Write more about this -->
 
-        </section>
+        </sect2>
         
-        <section id="performance-fetching-lazyproperties">
+        <sect2 id="performance-fetching-lazyproperties">
             <title>Using lazy property fetching</title>
 
             <para>
@@ -652,11 +652,11 @@
                 properties</literal> in HQL.
             </para>
 
-        </section>
+        </sect2>
 
-    </section>
+    </sect1>
 
-    <section id="performance-cache" revision="1">
+    <sect1 id="performance-cache" revision="1">
         <title>The Second Level Cache</title>
 
         <para>
@@ -741,7 +741,7 @@
             </tgroup>
         </table>
 
-        <section id="performance-cache-mapping" revision="2">
+        <sect2 id="performance-cache-mapping" revision="2">
             <title>Cache mappings</title>
 
             <para>
@@ -797,9 +797,9 @@
                 The <literal>usage</literal> attribute specifies a <emphasis>cache concurrency strategy</emphasis>.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="performance-cache-readonly">
+        <sect2 id="performance-cache-readonly">
             <title>Strategy: read only</title>
 
             <para>
@@ -813,10 +813,10 @@
     ....
 </class>]]></programlisting>
 
-        </section>
+        </sect2>
 
 
-        <section id="performance-cache-readwrite">
+        <sect2 id="performance-cache-readwrite">
             <title>Strategy: read/write</title>
 
             <para>
@@ -839,9 +839,9 @@
     </set>
 </class>]]></programlisting>
 
-        </section>
+        </sect2>
 
-        <section id="performance-cache-nonstrict">
+        <sect2 id="performance-cache-nonstrict">
             <title>Strategy: nonstrict read/write</title>
 
             <para>
@@ -853,9 +853,9 @@
                 <literal>Session.close()</literal> or <literal>Session.disconnect()</literal> is called.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="performance-cache-transactional">
+        <sect2 id="performance-cache-transactional">
             <title>Strategy: transactional</title>
 
             <para>
@@ -864,9 +864,9 @@
                 specify <literal>hibernate.transaction.manager_lookup_class</literal>. 
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="performance-cache-compat-matrix">
+        <sect2 id="performance-cache-compat-matrix">
             <title>Cache-provider/concurrency-strategy compatibility</title>
 
             <important>
@@ -943,11 +943,11 @@
                 </tgroup>
             </table>
 
-        </section>
+        </sect2>
 
-    </section>
+    </sect1>
 
-    <section id="performance-sessioncache" revision="2">
+    <sect1 id="performance-sessioncache" revision="2">
         <title>Managing the caches</title>
 
         <para>
@@ -965,7 +965,7 @@
             from the first-level cache.
         </para>
         
-        <programlisting><![CDATA[ScrollableResult cats = sess.createQuery("from Cat as cat").scroll(); //a huge result set
+        <programlisting><![CDATA[ScrollableResults cats = sess.createQuery("from Cat as cat").scroll(); //a huge result set
 while ( cats.next() ) {
     Cat cat = (Cat) cats.get(0);
     doSomethingWithACat(cat);
@@ -1041,9 +1041,9 @@
         <programlisting><![CDATA[hibernate.generate_statistics true
 hibernate.cache.use_structured_entries true]]></programlisting>       
                 
-    </section>
+    </sect1>
     
-    <section id="performance-querycache" revision="1">
+    <sect1 id="performance-querycache" revision="1">
         <title>The Query Cache</title>
 
         <para>
@@ -1092,9 +1092,9 @@
             a query cache region via <literal>SessionFactory.evictQueries()</literal>.
         </para>
 
-    </section>
+    </sect1>
 
-    <section id="performance-collections">
+    <sect1 id="performance-collections">
         <title>Understanding Collection performance</title>
 
         <para>
@@ -1103,7 +1103,7 @@
             collections at runtime.
         </para>
 
-        <section id="performance-collections-taxonomy">
+        <sect2 id="performance-collections-taxonomy">
             <title>Taxonomy</title>
 
             <para>Hibernate defines three basic kinds of collections:</para>
@@ -1180,9 +1180,9 @@
                 collection.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="performance-collections-mostefficientupdate">
+        <sect2 id="performance-collections-mostefficientupdate">
             <title>Lists, maps, idbags and sets are the most efficient collections to update</title>
 
             <para>
@@ -1215,9 +1215,9 @@
                 considerations of collection update performance simply do not apply.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="performance-collections-mostefficentinverse">
+        <sect2 id="performance-collections-mostefficentinverse">
             <title>Bags and lists are the most efficient inverse collections</title>
 
             <para>
@@ -1236,9 +1236,9 @@
 p.getChildren().add(c);  //no need to fetch the collection!
 sess.flush();]]></programlisting>
 
-        </section>
+        </sect2>
 
-        <section id="performance-collections-oneshotdelete">
+        <sect2 id="performance-collections-oneshotdelete">
             <title>One shot delete</title>
 
             <para>
@@ -1285,11 +1285,11 @@
                 One-shot-delete does not apply to collections mapped <literal>inverse="true"</literal>.
             </para>
 
-        </section>
+        </sect2>
 
-    </section>
+    </sect1>
 
-    <section id="performance-monitoring" revision="1">
+    <sect1 id="performance-monitoring" revision="1">
         <title>Monitoring performance</title>
 
         <para>
@@ -1298,7 +1298,7 @@
             Statistics in Hibernate are available per <literal>SessionFactory</literal>.
         </para>
 
-        <section id="performance-monitoring-sf" revision="2">
+        <sect2 id="performance-monitoring-sf" revision="2">
             <title>Monitoring a SessionFactory</title>
 
             <para>
@@ -1364,9 +1364,9 @@
                 method.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="performance-monitoring-metrics" revision="1">
+        <sect2 id="performance-monitoring-metrics" revision="1">
             <title>Metrics</title>
 
             <para>
@@ -1437,8 +1437,8 @@
                 <literal>getSecondLevelCacheRegionNames()</literal>.
             </para>
 
-        </section>
+        </sect2>
 
-    </section>
+    </sect1>
 
-</chapter>
+</chapter>
\ No newline at end of file

Modified: projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/persistent_classes.xml
===================================================================
--- projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/persistent_classes.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/persistent_classes.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -43,7 +43,7 @@
         ways (using trees of <literal>Map</literal> instances, for example).
     </para>
 
-    <section id="persistent-classes-pojo">
+    <sect1 id="persistent-classes-pojo">
         <title>A simple POJO example</title>
 
         <para>
@@ -123,8 +123,8 @@
     
     // addKitten not needed by Hibernate
     public void addKitten(Cat kitten) {
-    	kitten.setMother(this);
-	kitten.setLitterId( kittens.size() ); 
+        kitten.setMother(this);
+    kitten.setLitterId( kittens.size() ); 
         kittens.add(kitten);
     }
 }]]></programlisting>
@@ -134,7 +134,7 @@
         </para>
 
 
-        <section id="persistent-classes-pojo-constructor" revision="1">
+        <sect2 id="persistent-classes-pojo-constructor" revision="1">
             <title>Implement a no-argument constructor</title>
 
             <para>
@@ -144,9 +144,9 @@
                 default constructor with at least <emphasis>package</emphasis> visibility for runtime proxy 
                 generation in Hibernate.
             </para>
-        </section>
+        </sect2>
 
-        <section id="persistent-classes-pojo-identifier" revision="2">
+        <sect2 id="persistent-classes-pojo-identifier" revision="2">
             <title>Provide an identifier property (optional)</title>
 
             <para>
@@ -191,9 +191,9 @@
                 We recommend that you declare consistently-named identifier properties on persistent
                 classes and that you use a nullable (i.e., non-primitive) type.
             </para>
-        </section>
+        </sect2>
 
-        <section id="persistent-classes-pojo-final">
+        <sect2 id="persistent-classes-pojo-final">
             <title>Prefer non-final classes (optional)</title>
             <para>
                 A central feature of Hibernate, <emphasis>proxies</emphasis>, depends upon the
@@ -210,9 +210,9 @@
                 non-final classes. If you want to use a class with a <literal>public final</literal> 
                 method, you must explicitly disable proxying by setting <literal>lazy="false"</literal>.
             </para>
-        </section>
+        </sect2>
         
-        <section id="persistent-classes-pojo-accessors" revision="2">
+        <sect2 id="persistent-classes-pojo-accessors" revision="2">
             <title>Declare accessors and mutators for persistent fields (optional)</title>
 
             <para>
@@ -231,11 +231,11 @@
                 <literal>private</literal> get / set pair.
             </para>
 
-        </section>
+        </sect2>
 
-    </section>
+    </sect1>
 
-    <section id="persistent-classes-inheritance">
+    <sect1 id="persistent-classes-inheritance">
         <title>Implementing inheritance</title>
 
         <para>
@@ -255,9 +255,9 @@
                 this.name=name;
         }
 }]]></programlisting>
-    </section>
+    </sect1>
 
-    <section id="persistent-classes-equalshashcode" revision="1">
+    <sect1 id="persistent-classes-equalshashcode" revision="1">
         <title>Implementing <literal>equals()</literal> and <literal>hashCode()</literal></title>
 
         <para>
@@ -298,7 +298,7 @@
             an identifier value to the object. If <literal>equals()</literal> and <literal>hashCode()</literal>
             are based on the identifier value, the hash code would change, breaking the contract of the
             <literal>Set</literal>. See the Hibernate website for a full discussion of this problem. This is not 
-	    a Hibernate issue, but normal Java semantics of object identity and equality.
+        a Hibernate issue, but normal Java semantics of object identity and equality.
         </para>
 
         <para>
@@ -340,18 +340,18 @@
             candidates for a business key.
         </para>
 
-    </section>
+    </sect1>
 
-    <section id="persistent-classes-dynamicmodels">
+    <sect1 id="persistent-classes-dynamicmodels">
         <title>Dynamic models</title>
 
         
           <note><title>Note</title>
 <para>
-	 <emphasis>The following features are currently considered
+     <emphasis>The following features are currently considered
             experimental and may change in the near future.</emphasis>
-	      
-	</para>
+          
+    </para>
 </note>
         <para>
             Persistent entities do not necessarily have to be represented as POJO classes
@@ -423,7 +423,6 @@
 
         <programlisting><![CDATA[Session s = openSession();
 Transaction tx = s.beginTransaction();
-Session s = openSession();
 
 // Create a customer
 Map david = new HashMap();
@@ -464,7 +463,7 @@
 dynamicSession.save("Customer", david);
 ...
 dynamicSession.flush();
-dynamicSession.close()
+dynamicSession.close();
 ...
 // Continue on pojoSession
 ]]></programlisting>
@@ -485,9 +484,9 @@
             in <xref linkend="xml"/>.
         </para>
 
-    </section>
+    </sect1>
 
-    <section id="persistent-classes-tuplizers" revision="1">
+    <sect1 id="persistent-classes-tuplizers" revision="1">
         <title>Tuplizers</title>
 
         <para>
@@ -500,8 +499,8 @@
             constructor. It also knows how to access the POJO properties using the defined property accessors.
         </para>
 
-	<para> 
-	    There are two high-level types of Tuplizers, represented by the
+    <para> 
+        There are two high-level types of Tuplizers, represented by the
             <literal>org.hibernate.tuple.entity.EntityTuplizer</literal> and <literal>org.hibernate.tuple.component.ComponentTuplizer</literal>
             interfaces.  <literal>EntityTuplizer</literal>s are responsible for managing the above mentioned
             contracts in regards to entities, while <literal>ComponentTuplizer</literal>s do the same for
@@ -547,17 +546,17 @@
     private static final class CustomMapInstantiator
             extends org.hibernate.tuple.DynamicMapInstantitor {
         // override the generateMap() method to return our custom map...
-	    protected final Map generateMap() {
-		    return new CustomMap();
-	    }
+        protected final Map generateMap() {
+            return new CustomMap();
+        }
     }
 }]]></programlisting>
 
 
-    </section>
+    </sect1>
 
 
-    <section id="persistent-classes-entity-name-resolver" revision="0">
+    <sect1 id="persistent-classes-entity-name-resolver" revision="0">
         <title>EntityNameResolvers</title>
 
         <para>
@@ -579,40 +578,40 @@
  * trivial example meant only for illustration.
  */
 public final class DataProxyHandler implements InvocationHandler {
-	private String entityName;
-	private HashMap data = new HashMap();
+    private String entityName;
+    private HashMap data = new HashMap();
 
-	public DataProxyHandler(String entityName, Serializable id) {
-		this.entityName = entityName;
-		data.put( "Id", id );
-	}
+    public DataProxyHandler(String entityName, Serializable id) {
+        this.entityName = entityName;
+        data.put( "Id", id );
+    }
 
-	public Object invoke(Object proxy, Method method, Object[] args) throws Throwable {
-		String methodName = method.getName();
-		if ( methodName.startsWith( "set" ) ) {
-			String propertyName = methodName.substring( 3 );
-			data.put( propertyName, args[0] );
-		}
-		else if ( methodName.startsWith( "get" ) ) {
-			String propertyName = methodName.substring( 3 );
-			return data.get( propertyName );
-		}
-		else if ( "toString".equals( methodName ) ) {
-			return entityName + "#" + data.get( "Id" );
-		}
-		else if ( "hashCode".equals( methodName ) ) {
-			return new Integer( this.hashCode() );
-		}
-		return null;
-	}
+    public Object invoke(Object proxy, Method method, Object[] args) throws Throwable {
+        String methodName = method.getName();
+        if ( methodName.startsWith( "set" ) ) {
+            String propertyName = methodName.substring( 3 );
+            data.put( propertyName, args[0] );
+        }
+        else if ( methodName.startsWith( "get" ) ) {
+            String propertyName = methodName.substring( 3 );
+            return data.get( propertyName );
+        }
+        else if ( "toString".equals( methodName ) ) {
+            return entityName + "#" + data.get( "Id" );
+        }
+        else if ( "hashCode".equals( methodName ) ) {
+            return new Integer( this.hashCode() );
+        }
+        return null;
+    }
 
-	public String getEntityName() {
-		return entityName;
-	}
+    public String getEntityName() {
+        return entityName;
+    }
 
-	public HashMap getData() {
-		return data;
-	}
+    public HashMap getData() {
+        return data;
+    }
 }
 
 /**
@@ -663,13 +662,13 @@
 }
 
 public class MyEntityTuplizer extends PojoEntityTuplizer {
-	public MyEntityTuplizer(EntityMetamodel entityMetamodel, PersistentClass mappedEntity) {
-		super( entityMetamodel, mappedEntity );
-	}
+    public MyEntityTuplizer(EntityMetamodel entityMetamodel, PersistentClass mappedEntity) {
+        super( entityMetamodel, mappedEntity );
+    }
 
-	public EntityNameResolver[] getEntityNameResolvers() {
-		return new EntityNameResolver[] { MyEntityNameResolver.INSTANCE };
-	}
+    public EntityNameResolver[] getEntityNameResolvers() {
+        return new EntityNameResolver[] { MyEntityNameResolver.INSTANCE };
+    }
 
     public String determineConcreteSubclassEntityName(Object entityInstance, SessionFactoryImplementor factory) {
         String entityName = ProxyHelper.extractEntityName( entityInstance );
@@ -701,14 +700,14 @@
                 </listitem>
             </orderedlist>
         </para>
-    </section>
+    </sect1>
 
-    <!--<section id="persistent-classes-extensions">
+    <!--<sect1 id="persistent-classes-extensions">
         <title>Extensions</title>
         <para>
             TODO: Document user-extension framework in the property and proxy packages
         </para>
-    </section>-->
+    </sect1>-->
 
 </chapter>
 

Modified: projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/query_criteria.xml
===================================================================
--- projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/query_criteria.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/query_criteria.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -32,7 +32,7 @@
         Hibernate features an intuitive, extensible criteria query API.
     </para>
     
-    <section id="querycriteria-creating">
+    <sect1 id="querycriteria-creating">
         <title>Creating a <literal>Criteria</literal> instance</title>
 
         <para>
@@ -45,9 +45,9 @@
 crit.setMaxResults(50);
 List cats = crit.list();]]></programlisting>
 
-    </section>
+    </sect1>
      
-    <section id="querycriteria-narrowing">
+    <sect1 id="querycriteria-narrowing">
         <title>Narrowing the result set</title>
 
         <para>
@@ -82,7 +82,7 @@
         .add( Restrictions.eq("age", new Integer(0) ) )
         .add( Restrictions.eq("age", new Integer(1) ) )
         .add( Restrictions.eq("age", new Integer(2) ) )
-    ) )
+    )
     .list();]]></programlisting>
     
         <para>
@@ -113,13 +113,13 @@
         .add( age.eq( new Integer(0) ) )
         .add( age.eq( new Integer(1) ) )
         .add( age.eq( new Integer(2) ) )
-    ) )
+    )
     .add( Property.forName("name").in( new String[] { "Fritz", "Izi", "Pk" } ) )
     .list();]]></programlisting>
     
-   </section>
+   </sect1>
      
-    <section id="querycriteria-ordering">
+    <sect1 id="querycriteria-ordering">
         <title>Ordering the results</title>
 
         <para>
@@ -127,7 +127,7 @@
         </para>
 
         <programlisting><![CDATA[List cats = sess.createCriteria(Cat.class)
-    .add( Restrictions.like("name", "F%")
+    .add( Restrictions.like("name", "F%") )
     .addOrder( Order.asc("name") )
     .addOrder( Order.desc("age") )
     .setMaxResults(50)
@@ -140,9 +140,9 @@
     .setMaxResults(50)
     .list();]]></programlisting>
     
-    </section>
+    </sect1>
     
-    <section id="querycriteria-associations" revision="2">
+    <sect1 id="querycriteria-associations" revision="2">
         <title>Associations</title>
 
         <para>
@@ -196,9 +196,9 @@
     Cat kitten = (Cat) map.get("kt");
 }]]></programlisting>
 
-    </section>
+    </sect1>
     
-    <section id="querycriteria-dynamicfetching" revision="1">
+    <sect1 id="querycriteria-dynamicfetching" revision="1">
         <title>Dynamic association fetching</title>
 
         <para>
@@ -217,9 +217,9 @@
             by outer join. See <xref linkend="performance-fetching"/> for more information.
         </para>
     
-    </section>
+    </sect1>
      
-    <section id="querycriteria-examples">
+    <sect1 id="querycriteria-examples">
         <title>Example queries</title>
 
         <para>
@@ -262,9 +262,9 @@
         .add( Example.create( cat.getMate() ) )
     .list();]]></programlisting>
     
-    </section>
+    </sect1>
     
-    <section id="querycriteria-projection">
+    <sect1 id="querycriteria-projection">
         <title>Projections, aggregation and grouping</title>
         <para>
             The class <literal>org.hibernate.criterion.Projections</literal> is a
@@ -347,18 +347,18 @@
     
         <programlisting><![CDATA[List results = session.createCriteria(Cat.class)
     .setProjection( Projections.projectionList()
-        .add( Projections.rowCount().as("catCountByColor") )
+        .add( Projections.rowCount() )
         .add( Property.forName("weight").avg().as("avgWeight") )
         .add( Property.forName("weight").max().as("maxWeight") )
         .add( Property.forName("color").group().as("color" )
-    )
+    ) )
     .addOrder( Order.desc("catCountByColor") )
     .addOrder( Order.desc("avgWeight") )
     .list();]]></programlisting>
     
-    </section>
+    </sect1>
     
-    <section id="querycriteria-detachedqueries">
+    <sect1 id="querycriteria-detachedqueries">
         <title>Detached queries and subqueries</title>
         <para>
             The <literal>DetachedCriteria</literal> class allows you to create a query outside the scope 
@@ -403,13 +403,13 @@
     .add( Property.forName("weight").gt(avgWeightForSex) )
     .list();]]></programlisting>
 
-    </section>
+    </sect1>
 
         <!--TODO: ResultSetTransformer + aliasing. AliasToBeanTransformer allow returning arbitrary 
                   user objects - similar to setResultClass in JDO2. General use of ResultTransformer 
                   could also be explained. -->
                
-    <section id="query-criteria-naturalid">
+    <sect1 id="query-criteria-naturalid">
         <title>Queries by natural identifier</title>
         
         <para>
@@ -455,6 +455,6 @@
     ).setCacheable(true)
     .uniqueResult();]]></programlisting>
             
-    </section>
+    </sect1>
     
 </chapter>

Modified: projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/query_hql.xml
===================================================================
--- projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/query_hql.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/query_hql.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -218,24 +218,24 @@
     <section id="queryhql-joins-forms">
         <title>Forms of join syntax</title>
 
-	    <para>
-		    HQL supports two forms of association joining: <literal>implicit</literal> and <literal>explicit</literal>.
-		</para>
+        <para>
+            HQL supports two forms of association joining: <literal>implicit</literal> and <literal>explicit</literal>.
+        </para>
 
-	    <para>
-		    The queries shown in the previous section all use the <literal>explicit</literal> form, that is, where
-		    the join keyword is explicitly used in the from clause.  This is the recommended form.
-	    </para>
+        <para>
+            The queries shown in the previous section all use the <literal>explicit</literal> form, that is, where
+            the join keyword is explicitly used in the from clause.  This is the recommended form.
+        </para>
 
-	    <para>
-		    The <literal>implicit</literal> form does not use the join keyword.  Instead, the
-		    associations are "dereferenced" using dot-notation.  <literal>implicit</literal> joins
-		    can appear in any of the HQL clauses.  <literal>implicit</literal> join result
-		    in inner joins in the resulting SQL statement.
-	    </para>
+        <para>
+            The <literal>implicit</literal> form does not use the join keyword.  Instead, the
+            associations are "dereferenced" using dot-notation.  <literal>implicit</literal> joins
+            can appear in any of the HQL clauses.  <literal>implicit</literal> join result
+            in inner joins in the resulting SQL statement.
+        </para>
 
         <programlisting><![CDATA[from Cat as cat where cat.mate.name like '%s%']]></programlisting>
-	</section>
+    </section>
 
     <section id="queryhql-identifier-property">
         <title>Referring to identifier property</title>
@@ -265,14 +265,14 @@
             can be used to reference the identifier property.
         </para>
 
-	<important>
+    <important>
         <para>
             Please note that, starting in version 3.2.2, this has changed significantly. In previous versions,
             <literal>id</literal>  <emphasis>always</emphasis> referred to the identifier property
             regardless of its actual name.  A ramification of that decision was that non-identifier
             properties named <literal>id</literal> could never be referenced in Hibernate queries.
         </para>
-	</important>  
+    </important>  
 
   </section>
 
@@ -463,7 +463,7 @@
         <programlisting><![CDATA[from Cat where name='Fritz']]></programlisting>
 
         <para>
-        	If there is an alias, use a qualified property name:
+            If there is an alias, use a qualified property name:
         </para>
 
         <programlisting><![CDATA[from Cat as cat where cat.name='Fritz']]></programlisting>
@@ -472,8 +472,8 @@
             This returns instances of <literal>Cat</literal> named 'Fritz'.
         </para>
 
-	<para>
-	The following query: </para>
+    <para>
+    The following query: </para>
         <programlisting><![CDATA[select foo
 from Foo foo, Bar bar
 where foo.startDate = bar.date]]></programlisting>
@@ -543,13 +543,13 @@
         <para>
             Once again, the second query does not require a table join.
         </para>
-	
-	<para>
-	See <xref linkend="queryhql-identifier-property"/>
+    
+    <para>
+    See <xref linkend="queryhql-identifier-property"/>
             for more information regarding referencing identifier properties)
-	</para>
+    </para>
         
-	<para>
+    <para>
             The special property <literal>class</literal> accesses the discriminator value
             of an instance in the case of polymorphic persistence. A Java class name embedded in the
             where clause will be translated to its discriminator value.
@@ -620,7 +620,7 @@
             </listitem>
             <listitem>
                 <para>
-                	"Simple" case, <literal>case ... when ... then ... else ... end</literal>, and
+                    "Simple" case, <literal>case ... when ... then ... else ... end</literal>, and
                     "searched" case, <literal>case when ... then ... else ... end</literal>
                 </para>
             </listitem>
@@ -637,9 +637,9 @@
             </listitem>
             <listitem>
                 <para>
-					<literal>second(...)</literal>, <literal>minute(...)</literal>,
-					<literal>hour(...)</literal>, <literal>day(...)</literal>,
-					<literal>month(...)</literal>, and <literal>year(...)</literal>
+                    <literal>second(...)</literal>, <literal>minute(...)</literal>,
+                    <literal>hour(...)</literal>, <literal>day(...)</literal>,
+                    <literal>month(...)</literal>, and <literal>year(...)</literal>
                 </para>
             </listitem>
             <listitem>
@@ -1178,8 +1178,8 @@
             Collection elements can be ordered or grouped using a query filter:
         </para>
 
-        <programlisting><![CDATA[Collection orderedCollection = s.filter( collection, "order by this.amount" );
-Collection counts = s.filter( collection, "select this.type, count(this) group by this.type" );]]></programlisting>
+        <programlisting><![CDATA[Collection orderedCollection = s.createFilter( collection, "order by this.amount" ).list();
+  Collection counts = s.createFilter( collection, "select this.type, count(this) group by this.type" ).list();]]></programlisting>
 
         <para>
             You can find the size of a collection without initializing it:

Modified: projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/query_sql.xml
===================================================================
--- projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/query_sql.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/query_sql.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -37,7 +37,7 @@
   <para>Hibernate3 allows you to specify handwritten SQL, including stored
   procedures, for all create, update, delete, and load operations.</para>
 
-  <section id="querysql-creating" revision="4">
+  <sect1 id="querysql-creating" revision="4">
     <title>Using a <literal>SQLQuery</literal></title>
 
     <para>Execution of native SQL queries is controlled via the
@@ -45,7 +45,7 @@
     <literal>Session.createSQLQuery()</literal>. The following sections describe how
     to use this API for querying.</para>
 
-    <section>
+    <sect2>
       <title>Scalar queries</title>
 
       <para>The most basic SQL query is to get a list of scalars
@@ -67,7 +67,7 @@
       <programlisting><![CDATA[sess.createSQLQuery("SELECT * FROM CATS")
  .addScalar("ID", Hibernate.LONG)
  .addScalar("NAME", Hibernate.STRING)
- .addScalar("BIRTHDATE", Hibernate.DATE)
+ .addScalar("BIRTHDATE", Hibernate.DATE);
 ]]></programlisting>
 
       <para>This query specified:</para>
@@ -96,7 +96,7 @@
       <programlisting><![CDATA[sess.createSQLQuery("SELECT * FROM CATS")
  .addScalar("ID", Hibernate.LONG)
  .addScalar("NAME")
- .addScalar("BIRTHDATE")
+ .addScalar("BIRTHDATE");
 ]]></programlisting>
 
       <para>This is essentially the same query as before, but now
@@ -108,9 +108,9 @@
       not mapped, or does not result in the expected type, it is possible to
       customize it via calls to <literal>registerHibernateType</literal> in
       the Dialect.</para>
-    </section>
+    </sect2>
 
-    <section>
+    <sect2>
       <title>Entity queries</title>
 
       <para>The above queries were all about returning scalar values,
@@ -150,9 +150,9 @@
 ]]></programlisting>
 
       <para>This will allow cat.getDog() to function properly.</para>
-    </section>
+    </sect2>
 
-    <section>
+    <sect2>
       <title>Handling associations and collections</title>
 
       <para>It is possible to eagerly join in the <literal>Dog</literal> to
@@ -162,7 +162,7 @@
 
       <programlisting><![CDATA[sess.createSQLQuery("SELECT c.ID, NAME, BIRTHDATE, DOG_ID, D_ID, D_NAME FROM CATS c, DOGS d WHERE c.DOG_ID = d.D_ID")
  .addEntity("cat", Cat.class)
- .addJoin("cat.dog");
+ .addJoin("dog", "cat.dog"); 
 ]]></programlisting>
 
       <para>In this example, the returned <literal>Cat</literal>'s will have
@@ -175,7 +175,7 @@
 
       <programlisting><![CDATA[sess.createSQLQuery("SELECT ID, NAME, BIRTHDATE, D_ID, D_NAME, CAT_ID FROM CATS c, DOGS d WHERE c.ID = d.CAT_ID")
  .addEntity("cat", Cat.class)
- .addJoin("cat.dogs");
+ .addJoin("dog", "cat.dogs"); 
 ]]></programlisting>
 
         <para>
@@ -183,9 +183,9 @@
             enhance the sql queries to make them usable in Hibernate. Problems can arise when returning
             multiple entities of the same type or when the default alias/column names are not enough.
         </para>
-    </section>
+    </sect2>
 
-    <section>
+    <sect2>
       <title>Returning multiple entities</title>
 
       <para>Until now, the result set column names are assumed to be the same
@@ -203,14 +203,14 @@
 
       
 
-	<para>
-	The query was intended to return two Cat instances per
-	row: a cat and its mother. The query will, however, fail because there is a conflict of
-	names; the instances are mapped to the same column names. Also, on some	
-	databases the returned column aliases will most likely be on the form
-	"c.ID", "c.NAME", etc. which are not equal to the columns specified in
-	the mappings ("ID" and "NAME").
-	</para>
+    <para>
+    The query was intended to return two Cat instances per
+    row: a cat and its mother. The query will, however, fail because there is a conflict of
+    names; the instances are mapped to the same column names. Also, on some 
+    databases the returned column aliases will most likely be on the form
+    "c.ID", "c.NAME", etc. which are not equal to the columns specified in
+    the mappings ("ID" and "NAME").
+    </para>
 
       <para>The following form is not vulnerable to column name
       duplication:</para>
@@ -251,7 +251,7 @@
         .addEntity("mother", Cat.class).list()
 ]]></programlisting>
 
-      <section id="querysql-aliasreferences" revision="2">
+      <sect3 id="querysql-aliasreferences" revision="2">
         <title>Alias and property references</title>
 
         <para>In most cases the above alias injection is needed. For
@@ -368,10 +368,10 @@
             </tbody>
           </tgroup>
         </table>
-      </section>
-    </section>
+      </sect3>
+    </sect2>
 
-    <section>
+    <sect2>
       <title>Returning non-managed entities</title>
 
       <para>It is possible to apply a ResultTransformer to native SQL queries, allowing it to return non-managed entities.</para>
@@ -395,17 +395,17 @@
         The above query will return a list of <literal>CatDTO</literal> which has been instantiated and injected the values of NAME and BIRTHNAME into its corresponding
         properties or fields.
         </para>
-    </section>
+    </sect2>
 
-    <section>
+    <sect2>
       <title>Handling inheritance</title>
 
       <para>Native SQL queries which query for entities that are mapped as part
       of an inheritance must include all properties for the baseclass and all
       its subclasses.</para>
-    </section>
+    </sect2>
 
-    <section>
+    <sect2>
       <title>Parameters</title>
 
       <para>Native SQL queries support positional as well as named
@@ -416,13 +416,13 @@
      
 query = sess.createSQLQuery("SELECT * FROM CATS WHERE NAME like :name").addEntity(Cat.class);
 List pusList = query.setString("name", "Pus%").list();          ]]></programlisting>
-    </section>
+    </sect2>
     
     
         
-  </section>
+  </sect1>
 
-  <section id="querysql-namedqueries" revision="3">
+  <sect1 id="querysql-namedqueries" revision="3">
     <title>Named SQL queries</title>
 
     <para>Named SQL queries can be defined in the mapping document and called
@@ -509,7 +509,7 @@
     .setResultSetMapping("catAndKitten")
     .list();]]></programlisting>
 
-    <section id="propertyresults">
+    <sect2 id="propertyresults">
       <title>Using return-property to explicitly specify column/alias
       names</title>
 
@@ -560,9 +560,9 @@
       <para>If your mapping has a discriminator you must use
       <literal>&lt;return-discriminator&gt;</literal> to specify the
       discriminator column.</para>
-    </section>
+    </sect2>
 
-    <section id="sp_query" revision="1">
+    <sect2 id="sp_query" revision="1">
       <title>Using stored procedures for querying</title>
 
       <para>Hibernate3 provides support for queries via stored procedures
@@ -607,7 +607,7 @@
       entities. <literal>&lt;return-join&gt;</literal> and
       <literal>&lt;load-collection&gt;</literal> are not supported.</para>
 
-      <section id="querysql-limits-storedprocedures" revision="1">
+      <sect3 id="querysql-limits-storedprocedures" revision="1">
         <title>Rules/limitations for using stored procedures</title>
 
         <para>You cannot use stored procedures with Hibernate unless you follow some procedure/function
@@ -655,11 +655,11 @@
             requirement.</para>
           </listitem>
         </itemizedlist>
-      </section>
-    </section>
-  </section>
+      </sect3>
+    </sect2>
+  </sect1>
 
-  <section id="querysql-cud">
+  <sect1 id="querysql-cud">
     <title>Custom SQL for create, update and delete</title>
 
     <para>Hibernate3 can use custom SQL statements for create, update, and
@@ -726,9 +726,9 @@
     return SQL%ROWCOUNT;
 
 END updatePerson;]]></programlisting>
-  </section>
+  </sect1>
 
-  <section id="querysql-load">
+  <sect1 id="querysql-load">
     <title>Custom SQL for loading</title>
 
     <para>You can also declare your own SQL (or HQL) queries for entity
@@ -783,5 +783,5 @@
         ON pers.ID = emp.PERSON_ID
     WHERE ID=?
 </sql-query>]]></programlisting>
-  </section>
+  </sect1>
 </chapter>

Modified: projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/session_api.xml
===================================================================
--- projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/session_api.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/session_api.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -156,8 +156,7 @@
 pk.setSex('F');
 pk.setName("PK");
 pk.setKittens( new HashSet() );
-pk.addKitten(fritz);
-sess.save( pk, new Long(1234) );]]></programlisting>
+pk.addKitten(fritz);]]></programlisting>
         
         <para>
             If the object you make persistent has associated objects (e.g. the
@@ -224,7 +223,6 @@
         <programlisting><![CDATA[Cat cat = (Cat) sess.get(Cat.class, id);
 if (cat==null) {
     cat = new Cat();
-    sess.save(cat, id);
 }
 return cat;]]></programlisting>
 
@@ -301,9 +299,9 @@
 Cat mother = (Cat) session.createQuery(
     "select cat.mother from Cat as cat where cat = ?")
     .setEntity(0, izi)
-    .uniqueResult();]]
+    .uniqueResult();
 
-Query mothersWithKittens = (Cat) session.createQuery(
+Query mothersWithKittens = session.createQuery(
     "select mother from Cat as mother left join fetch mother.kittens");
 Set uniqueMothers = new HashSet(mothersWithKittens.list());]]></programlisting>
 
@@ -337,11 +335,11 @@
 Iterator iter = sess.createQuery("from eg.Qux q order by q.likeliness").iterate();
 while ( iter.hasNext() ) {
     Qux qux = (Qux) iter.next();  // fetch the object
-    // something we couldnt express in the query
+    // something we couldn't express in the query
     if ( qux.calculateComplicatedAlgorithm() ) {
         // delete the current instance
         iter.remove();
-        // dont need to process the rest
+        // don't need to process the rest
         break;
     }
 }]]></programlisting>
@@ -495,7 +493,7 @@
     while( ( PAGE_SIZE > i++ ) && cats.next() ) pageOfCats.add( cats.get(1) );
 
 }
-cats.close()]]></programlisting>
+cats.close();]]></programlisting>
 
                 <para>
                     Note that an open database connection and cursor is required for this
@@ -526,7 +524,7 @@
 
                 <programlisting><![CDATA[Query q = sess.getNamedQuery("ByNameAndMaximumWeight");
 q.setString(0, name);
-q.setInt(1, minWeight);
+q.setInteger(1, minWeight);
 List cats = q.list();]]></programlisting>
 
                 <para>
@@ -560,7 +558,7 @@
     "where this.color = ?")
     .setParameter( Color.BLACK, Hibernate.custom(ColorUserType.class) )
     .list()
-);]]></programlisting>
+]]></programlisting>
         
             <para>
                 The returned collection is considered a bag that is a copy of the given
@@ -631,7 +629,7 @@
            "{cat}.MATE AS {cat.mate}, {cat}.SUBCLASS AS {cat.class}, ... " +
     "FROM CAT {cat} WHERE ROWNUM<10")
     .addEntity("cat", Cat.class)
-.list()]]></programlisting>
+.list();]]></programlisting>
 
             <para>
                 SQL queries can contain named and positional parameters, just like Hibernate queries.
@@ -920,18 +918,18 @@
     </section>
     
     <section id="objectstate-replicating" revision="1">
-    	<title>Replicating object between two different datastores</title>
-    	
-    	<para>
-    	    It is sometimes useful to be able to take a graph of persistent instances
-    	    and make them persistent in a different datastore, without regenerating identifier
-    	    values.
-    	</para>
-    	
+        <title>Replicating object between two different datastores</title>
+        
+        <para>
+            It is sometimes useful to be able to take a graph of persistent instances
+            and make them persistent in a different datastore, without regenerating identifier
+            values.
+        </para>
+        
         <programlisting><![CDATA[//retrieve a cat from one database
 Session session1 = factory1.openSession();
 Transaction tx1 = session1.beginTransaction();
-Cat cat = session1.get(Cat.class, catId);
+Cat cat = (Cat) session1.get(Cat.class, catId);
 tx1.commit();
 session1.close();
 
@@ -980,7 +978,7 @@
             instances, upgrading system configuration information during product upgrades,
             rolling back changes made during non-ACID transactions and more.
         </para>
-    	
+        
     </section>
 
     <section id="objectstate-flushing">
@@ -1081,7 +1079,7 @@
 izi.setName(iznizi);
 
 // might return stale data
-sess.find("from Cat as cat left outer join cat.kittens kitten");
+sess.createQuery("from Cat as cat left outer join cat.kittens kitten");
 
 // change to izi is not flushed!
 ...
@@ -1270,7 +1268,7 @@
         <programlisting><![CDATA[Cat fritz = ......;
 ClassMetadata catMeta = sessionfactory.getClassMetadata(Cat.class);
 
-Object[] propertyValues = catMeta.getPropertyValues(fritz);
+Object[] propertyValues = catMeta.getPropertyValues(fritz, EntityMode.POJO);
 String[] propertyNames = catMeta.getPropertyNames();
 Type[] propertyTypes = catMeta.getPropertyTypes();
 

Modified: projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/transactions.xml
===================================================================
--- projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/transactions.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/transactions.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -150,7 +150,7 @@
             <para>
                 Your application code can access a "current session" to process the request
                 by calling <literal>sessionFactory.getCurrentSession()</literal>. 
-		You will always get a <literal>Session</literal> scoped
+        You will always get a <literal>Session</literal> scoped
                 to the current database transaction. This has to be configured for either
                 resource-local or JTA environments, see <xref linkend="architecture-current-session"/>.
             </para>
@@ -228,7 +228,7 @@
                         <emphasis>Automatic Versioning</emphasis>: Hibernate can perform automatic
                         optimistic concurrency control for you. It can automatically detect
                         if a concurrent modification occurred during user think time. Check for this at 
-			the end of the conversation.
+            the end of the conversation.
                     </para>
                 </listitem>
                 <listitem>
@@ -453,8 +453,8 @@
             <para>
                 If a Hibernate persistence layer runs in a non-managed environment, database connections
                 are usually handled by simple (i.e., non-DataSource) connection pools from which
-	            Hibernate obtains connections as needed. The session/transaction handling idiom looks
-	            like this:
+                Hibernate obtains connections as needed. The session/transaction handling idiom looks
+                like this:
             </para>
 
             <programlisting><![CDATA[// Non-managed environment idiom
@@ -479,7 +479,7 @@
             <para>
                 You do not have to <literal>flush()</literal> the <literal>Session</literal> explicitly:
                 the call to <literal>commit()</literal> automatically triggers the synchronization depending
-	            on the <xref linkend="objectstate-flushing" /> for the session.
+                on the <xref linkend="objectstate-flushing" /> for the session.
                 A call to <literal>close()</literal> marks the end of a session. The main implication
                 of <literal>close()</literal> is that the JDBC connection will be relinquished by the
                 session. This Java code is portable and runs in both non-managed and JTA environments.
@@ -726,7 +726,7 @@
     // do some work
     ...
 
-    sess.getTransaction().commit()
+    sess.getTransaction().commit();
 }
 catch (RuntimeException e) {
     sess.getTransaction().rollback();
@@ -776,7 +776,7 @@
 
 int oldVersion = foo.getVersion();
 session.load( foo, foo.getKey() ); // load the current state
-if ( oldVersion != foo.getVersion() ) throw new StaleObjectStateException();
+if ( oldVersion != foo.getVersion() ) throw new StaleObjectStateException("Message", foo.getId()); 
 foo.setProperty("bar");
 
 t.commit();
@@ -862,10 +862,10 @@
 
             <note>
            <title>Note</title>
-	   <para>Earlier versions of Hibernate required explicit disconnection and reconnection
+       <para>Earlier versions of Hibernate required explicit disconnection and reconnection
                 of a <literal>Session</literal>. These methods are deprecated, as beginning and
                 ending a transaction has the same effect.
-	    </para>
+        </para>
             </note>
 
             <para>
@@ -933,7 +933,7 @@
                 even timestamps. In both cases, versioning cannot rely on a particular column in a table.
                 To force a version check with a
                 comparison of the state of all fields in a row but without a version or timestamp property mapping, 
-		turn on <literal>optimistic-lock="all"</literal>
+        turn on <literal>optimistic-lock="all"</literal>
                 in the <literal>&lt;class&gt;</literal> mapping. This conceptually only works
                 if Hibernate can compare the old and the new state (i.e., if you use a single long
                 <literal>Session</literal> and not session-per-request-with-detached-objects).

Modified: projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/tutorial.xml
===================================================================
--- projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/tutorial.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/5.0/Hibernate/Hibernate_Core/en-US/tutorial.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -55,7 +55,7 @@
         </para>
     </note>
 
-    <section id="tutorial-firstapp">
+    <sect1 id="tutorial-firstapp">
         <title>Part 1 - The first Hibernate Application</title>
 
         <para>
@@ -72,7 +72,7 @@
             </para>
         </note>
 
-        <section id="tutorial-firstapp-setup">
+        <sect2 id="tutorial-firstapp-setup">
             <title>Setup</title>
 
             <para>
@@ -91,49 +91,79 @@
                 many IDEs to automatically set up a project for us based on the maven descriptor.
             </para>
 
-        <programlisting><![CDATA[<project xmlns="http://maven.apache.org/POM/4.0.0"
-         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
-
+        <programlisting><![CDATA[<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://
+maven.apache.org/xsd/maven-4.0.0.xsd">
     <modelVersion>4.0.0</modelVersion>
-
     <groupId>org.hibernate.tutorials</groupId>
     <artifactId>hibernate-tutorial</artifactId>
     <version>1.0.0-SNAPSHOT</version>
+    <packaging>war</packaging>
     <name>First Hibernate Tutorial</name>
+    <build>
+        <!--
+            we dont want the version to be part of the generated war file name
+        -->
+        <finalName>${artifactId}</finalName>
+        <!--
+            we dont want to use the jars maven provided, we want to use JBoss' ones
+        -->
+        <plugins>
+            <plugin>
+                <artifactId>maven-war-plugin</artifactId>
+                <configuration>
+                    <packagingExcludes>WEB-INF/lib/*.jar</packagingExcludes>
+                </configuration>
+            </plugin>
+        </plugins>
 
-    <build>
-         <!-- we dont want the version to be part of the generated war file name -->
-         <finalName>${artifactId}</finalName>
     </build>
-
     <dependencies>
         <dependency>
             <groupId>org.hibernate</groupId>
             <artifactId>hibernate-core</artifactId>
+            <version>3.3.2.GA</version>
         </dependency>
-
-        <!-- Because this is a web app, we also have a dependency on the servlet api. -->
+        <!--
+            Because this is a web app, we also have a dependency on the servlet
+            api.
+        -->
         <dependency>
             <groupId>javax.servlet</groupId>
             <artifactId>servlet-api</artifactId>
+            <version>2.3</version>
         </dependency>
-
-        <!-- Hibernate uses slf4j for logging, for our purposes here use the simple backend -->
+        <!--
+            Hibernate uses slf4j for logging, for our purposes here use the
+            simple backend
+        -->
         <dependency>
             <groupId>org.slf4j</groupId>
             <artifactId>slf4j-simple</artifactId>
+            <version>1.5.8</version>
         </dependency>
-
-        <!-- Hibernate gives you a choice of bytecode providers between cglib and javassist -->
+        <!--
+            Hibernate gives you a choice of bytecode providers between cglib and
+            javassist
+        -->
         <dependency>
             <groupId>javassist</groupId>
             <artifactId>javassist</artifactId>
+            <version>3.9.0.GA</version>
         </dependency>
+        <!--
+            We will use the HSQLDB as the backend database for our tutorial
+        -->
+        <dependency>
+            <groupId>hsqldb</groupId>
+            <artifactId>hsqldb</artifactId>
+            <version>1.8.0.2</version>
+        </dependency>
     </dependencies>
+</project>
+    
+]]></programlisting>
 
-</project>]]></programlisting>
-
             <note>
                 <para>
                     It is not a requirement to use Maven.  If you wish to use another technology to
@@ -155,10 +185,10 @@
             <para>
                 Save this file as <filename>pom.xml</filename> in the project root directory.
             </para>
-        </section>
+        </sect2>
 
 
-        <section id="tutorial-firstapp-firstclass">
+        <sect2 id="tutorial-firstapp-firstclass">
             <title>The first class</title>
             
             <para>
@@ -238,9 +268,9 @@
                 Save this file to the <filename>src/main/java/org/hibernate/tutorial/domain</filename>
                 directory.
             </para>
-        </section>
+        </sect2>
 
-        <section id="tutorial-firstapp-mapping">
+        <sect2 id="tutorial-firstapp-mapping">
             <title>The mapping file</title>
 
             <para>
@@ -414,9 +444,9 @@
                 <filename>src/main/resources/org/hibernate/tutorial/domain/Event.hbm.xml</filename>.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="tutorial-firstapp-configuration" revision="2">
+        <sect2 id="tutorial-firstapp-configuration" revision="2">
             <title>Hibernate configuration</title>
 
             <para>
@@ -541,9 +571,9 @@
                 <filename>src/main/resources</filename> directory.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="tutorial-firstapp-mvn" revision="1">
+        <sect2 id="tutorial-firstapp-mvn" revision="1">
             <title>Building with Maven</title>
 
             <para>
@@ -574,9 +604,9 @@
 [INFO] Final Memory: 5M/547M
 [INFO] ------------------------------------------------------------------------]]></programlisting>
 
-        </section>
+        </sect2>
 
-        <section id="tutorial-firstapp-helpers" revision="3">
+        <sect2 id="tutorial-firstapp-helpers" revision="3">
             <title>Startup and helpers</title>
 
             <para>
@@ -664,9 +694,9 @@
                 Hibernate.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="tutorial-firstapp-workingpersistence" revision="5">
+        <sect2 id="tutorial-firstapp-workingpersistence" revision="5">
             <title>Loading and storing objects</title>
 
             <para>
@@ -854,11 +884,11 @@
                 <command>mvn exec:java -Dexec.mainClass="org.hibernate.tutorial.EventManager" -Dexec.args="list"</command>
             </para>
 
-        </section>
+        </sect2>
 
-    </section>
+    </sect1>
 
-    <section id="tutorial-associations">
+    <sect1 id="tutorial-associations">
         <title>Part 2 - Mapping associations</title>
 
         <para>
@@ -868,7 +898,7 @@
             which they participate.
         </para>
 
-        <section id="tutorial-associations-mappinguser" revision="1">
+        <sect2 id="tutorial-associations-mappinguser" revision="1">
             <title>Mapping the Person class</title>
 
             <para>
@@ -914,7 +944,7 @@
 </hibernate-mapping>]]></programlisting>
 
             <para>
-                Finally, add the new mapping to Hibernate's configuration:
+                Finally, add the new mapping to Hibernate's configuration immediately after the existing mapping for <filename>Event.hbm.xml</filename>:
             </para>
 
             <programlisting><![CDATA[<mapping resource="events/Event.hbm.xml"/>
@@ -927,9 +957,9 @@
                 behavior.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="tutorial-associations-unidirset" revision="3">
+        <sect2 id="tutorial-associations-unidirset" revision="3">
             <title>A unidirectional Set-based association</title>
 
             <para>
@@ -1018,9 +1048,9 @@
                                                   |_____________|
  ]]></programlisting>
 
-        </section>
+        </sect2>
 
-        <section id="tutorial-associations-working" revision="2">
+        <sect2 id="tutorial-associations-working" revision="2">
             <title>Working the association</title>
 
             <para>
@@ -1139,9 +1169,9 @@
                 entities, but looks almost the same in Java.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="tutorial-associations-valuecollections">
+        <sect2 id="tutorial-associations-valuecollections">
             <title>Collection of values</title>
 
             <para>
@@ -1231,9 +1261,9 @@
                 optimize this with an eager fetch.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="tutorial-associations-bidirectional" revision="1">
+        <sect2 id="tutorial-associations-bidirectional" revision="1">
             <title>Bi-directional associations</title>
 
             <para>
@@ -1271,10 +1301,12 @@
                 Now map this side of the association in <literal>Event.hbm.xml</literal>.
             </para>
 
-            <programlisting><![CDATA[        <set name="participants" table="PERSON_EVENT" inverse="true">
-            <key column="EVENT_ID"/>
-            <many-to-many column="PERSON_ID" class="events.Person"/>
-        </set>]]></programlisting>
+            <programlisting><![CDATA[
+<set name="participants" table="PERSON_EVENT" inverse="true">
+  <key column="EVENT_ID"/>
+  <many-to-many column="PERSON_ID" class="org.hibernate.tutorial.domain.Person"/>
+</set>
+            ]]></programlisting>
 
             <para>
                 These are normal <literal>set</literal> mappings in both mapping documents.
@@ -1290,9 +1322,9 @@
                 understand once you see how the bi-directional link between our two entities is created.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="tutorial-associations-usingbidir">
+        <sect2 id="tutorial-associations-usingbidir">
             <title>Working bi-directional links</title>
 
             <para>
@@ -1346,11 +1378,11 @@
                 and in many-to-many association you can select either side.
             </para>
 
-        </section>
+        </sect2>
 
-    </section>
+    </sect1>
 
-    <section id="tutorial-webapp">
+    <sect1 id="tutorial-webapp">
         <title>Part 3 - The EventManager web application</title>
 
         <para>
@@ -1360,7 +1392,7 @@
             database, and it provides an HTML form to enter new events.
         </para>
 
-        <section id="tutorial-webapp-servlet" revision="2">
+        <sect2 id="tutorial-webapp-servlet" revision="2">
             <title>Writing the basic servlet</title>
 
             <para>
@@ -1440,9 +1472,9 @@
                 as you consider rendering your view in JSP, not in a servlet.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="tutorial-webapp-processing" revision="1">
+        <sect2 id="tutorial-webapp-processing" revision="1">
             <title>Processing and rendering</title>
 
             <para>
@@ -1550,9 +1582,9 @@
                 examples.
             </para>
 
-        </section>
+        </sect2>
 
-        <section id="tutorial-webapp-deploy">
+        <sect2 id="tutorial-webapp-deploy">
             <title>Deploying and testing</title>
 
             <para>
@@ -1581,31 +1613,30 @@
             <para>
                 To build and deploy call <literal>mvn package</literal> in your
                 project directory and copy the <filename>hibernate-tutorial.war</filename>
-                file into your Tomcat <filename>webapps</filename> directory.
+                file into your <filename>$JBOSS_HOME/server/$CONFIG/deploy</filename> directory.
             </para>
 
-            <note>
+<!--            <note>
                 <para>
                     If you do not have Tomcat installed, download it from
                     <ulink url="http://tomcat.apache.org/"/> and follow the
                     installation instructions.  Our application requires
                     no changes to the standard Tomcat configuration.
                 </para>
-            </note>
+            </note>-->
 
             <para>
-                Once deployed and Tomcat is running, access the application at
-                <literal>http://localhost:8080/hibernate-tutorial/eventmanager</literal>. Make
-                sure you watch the Tomcat log to see Hibernate initialize when the first
+                Once deployed and JBoss is running, access the application at
+                <literal>http://localhost:8080/hibernate-tutorial/eventmanager</literal>. Watch the server log (in <filename>$JBOSS_HOME/server/$CONFIG/log/server.log</filename>) to see Hibernate initialize when the first
                 request hits your servlet (the static initializer in <literal>HibernateUtil</literal>
                 is called) and to get the detailed output if any exceptions occurs.
             </para>
 
-        </section>
+        </sect2>
 
-    </section>
+    </sect1>
 
-    <section id="tutorial-summary" revision="1">
+    <sect1 id="tutorial-summary" revision="1">
         <title>Summary</title>
 
         <para>
@@ -1614,6 +1645,6 @@
             <ulink url="http://hibernate.org">website</ulink>.
         </para>
 
-    </section>
+    </sect1>
 
 </chapter>

Modified: projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/batch.xml
===================================================================
--- projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/batch.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/batch.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -75,7 +75,7 @@
         <literal>CacheMode</literal> to disable interaction with the second-level cache.
     </para>
 
-    <sect1 id="batch-inserts">
+    <section id="batch-inserts">
         <title>Batch inserts</title>
 
         <para>
@@ -100,9 +100,9 @@
 tx.commit();
 session.close();]]></programlisting>
 
-    </sect1>
+    </section>
 
-    <sect1 id="batch-update" >
+    <section id="batch-update" >
         <title>Batch updates</title>
 
         <para>
@@ -131,9 +131,9 @@
 tx.commit();
 session.close();]]></programlisting>
 
-    </sect1>
+    </section>
     
-    <sect1 id="batch-statelesssession">
+    <section id="batch-statelesssession">
         <title>The StatelessSession interface</title>
         <para>
             Alternatively, Hibernate provides a command-oriented API that can be used for 
@@ -180,9 +180,9 @@
             interface.
         </para>
 
-    </sect1>
+    </section>
 
-    <sect1 id="batch-direct" revision="3">
+    <section id="batch-direct" revision="3">
         <title>DML-style operations</title>
 
         <para>
@@ -372,6 +372,6 @@
 tx.commit();
 session.close();]]></programlisting>
 
-    </sect1>
+    </section>
 
 </chapter>

Modified: projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/events.xml
===================================================================
--- projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/events.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/events.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -34,7 +34,7 @@
         functionality and the extension of Hibernate functionality.
     </para>
 
-    <sect1 id="objectstate-interceptors" revision="3">
+    <section id="objectstate-interceptors" revision="3">
         <title>Interceptors</title>
 
         <para>
@@ -160,9 +160,9 @@
     
         <programlisting><![CDATA[new Configuration().setInterceptor( new AuditInterceptor() );]]></programlisting>
 
-    </sect1>
+    </section>
 
-     <sect1 id="objectstate-events" revision="4">
+     <section id="objectstate-events" revision="4">
         <title>Event system</title>
 
         <para>
@@ -249,9 +249,9 @@
             or off during configuration.
         </para>
 
-    </sect1>
+    </section>
     
-    <sect1 id="objectstate-decl-security" revision="2">
+    <section id="objectstate-decl-security" revision="2">
         <title>Hibernate declarative security</title>
         <para>
             Usually, declarative security in Hibernate applications is managed in a session facade
@@ -286,7 +286,7 @@
             The role names are the roles understood by your JACC provider.
         </para>
        
-    </sect1>
+    </section>
 
 </chapter>
 

Modified: projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/performance.xml
===================================================================
--- projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/performance.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/performance.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -28,7 +28,7 @@
 <chapter id="performance">
     <title>Improving performance</title>
 
-    <sect1 id="performance-fetching" revision="2">
+    <section id="performance-fetching" revision="2">
         <title>Fetching strategies</title>
 
         <para>
@@ -139,7 +139,7 @@
             in any detached instance of a particular class.
         </para>
  
-        <sect2 id="performance-fetching-lazy">
+        <section id="performance-fetching-lazy">
             <title>Working with lazy associations</title>
             
             <para>
@@ -198,9 +198,9 @@
                 collections.
             </para>
         
-        </sect2>
+        </section>
         
-        <sect2 id="performance-fetching-custom" revision="4">
+        <section id="performance-fetching-custom" revision="4">
             <title>Tuning fetch strategies</title>
             
             <para>
@@ -278,9 +278,9 @@
                 second-level cache.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="performance-fetching-proxies" revision="2">
+        <section id="performance-fetching-proxies" revision="2">
             <title>Single-ended association proxies</title>
 
             <para>
@@ -427,9 +427,9 @@
                 will result in immediate proxy initialization.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="performance-fetching-initialization" revision="1">
+        <section id="performance-fetching-initialization" revision="1">
             <title>Initializing collections and proxies</title>
 
             <para>
@@ -521,9 +521,9 @@
 
             <programlisting><![CDATA[s.createFilter( lazyCollection, "").setFirstResult(0).setMaxResults(10).list();]]></programlisting>
 
-        </sect2>
+        </section>
 
-        <sect2 id="performance-fetching-batch">
+        <section id="performance-fetching-batch">
             <title>Using batch fetching</title>
 
             <para>
@@ -575,9 +575,9 @@
                 <emphasis>materialized path</emphasis> might be a better option for read-mostly trees.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="performance-fetching-subselect">
+        <section id="performance-fetching-subselect">
             <title>Using subselect fetching</title>
 
             <para>
@@ -588,9 +588,9 @@
             
             <!-- TODO: Write more about this -->
 
-        </sect2>
+        </section>
         
-        <sect2 id="performance-fetching-lazyproperties">
+        <section id="performance-fetching-lazyproperties">
             <title>Using lazy property fetching</title>
 
             <para>
@@ -652,11 +652,11 @@
                 properties</literal> in HQL.
             </para>
 
-        </sect2>
+        </section>
 
-    </sect1>
+    </section>
 
-    <sect1 id="performance-cache" revision="1">
+    <section id="performance-cache" revision="1">
         <title>The Second Level Cache</title>
 
         <para>
@@ -741,7 +741,7 @@
             </tgroup>
         </table>
 
-        <sect2 id="performance-cache-mapping" revision="2">
+        <section id="performance-cache-mapping" revision="2">
             <title>Cache mappings</title>
 
             <para>
@@ -797,9 +797,9 @@
                 The <literal>usage</literal> attribute specifies a <emphasis>cache concurrency strategy</emphasis>.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="performance-cache-readonly">
+        <section id="performance-cache-readonly">
             <title>Strategy: read only</title>
 
             <para>
@@ -813,10 +813,10 @@
     ....
 </class>]]></programlisting>
 
-        </sect2>
+        </section>
 
 
-        <sect2 id="performance-cache-readwrite">
+        <section id="performance-cache-readwrite">
             <title>Strategy: read/write</title>
 
             <para>
@@ -839,9 +839,9 @@
     </set>
 </class>]]></programlisting>
 
-        </sect2>
+        </section>
 
-        <sect2 id="performance-cache-nonstrict">
+        <section id="performance-cache-nonstrict">
             <title>Strategy: nonstrict read/write</title>
 
             <para>
@@ -853,9 +853,9 @@
                 <literal>Session.close()</literal> or <literal>Session.disconnect()</literal> is called.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="performance-cache-transactional">
+        <section id="performance-cache-transactional">
             <title>Strategy: transactional</title>
 
             <para>
@@ -864,9 +864,9 @@
                 specify <literal>hibernate.transaction.manager_lookup_class</literal>. 
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="performance-cache-compat-matrix">
+        <section id="performance-cache-compat-matrix">
             <title>Cache-provider/concurrency-strategy compatibility</title>
 
             <important>
@@ -943,11 +943,11 @@
                 </tgroup>
             </table>
 
-        </sect2>
+        </section>
 
-    </sect1>
+    </section>
 
-    <sect1 id="performance-sessioncache" revision="2">
+    <section id="performance-sessioncache" revision="2">
         <title>Managing the caches</title>
 
         <para>
@@ -1041,9 +1041,9 @@
         <programlisting><![CDATA[hibernate.generate_statistics true
 hibernate.cache.use_structured_entries true]]></programlisting>       
                 
-    </sect1>
+    </section>
     
-    <sect1 id="performance-querycache" revision="1">
+    <section id="performance-querycache" revision="1">
         <title>The Query Cache</title>
 
         <para>
@@ -1092,9 +1092,9 @@
             a query cache region via <literal>SessionFactory.evictQueries()</literal>.
         </para>
 
-    </sect1>
+    </section>
 
-    <sect1 id="performance-collections">
+    <section id="performance-collections">
         <title>Understanding Collection performance</title>
 
         <para>
@@ -1103,7 +1103,7 @@
             collections at runtime.
         </para>
 
-        <sect2 id="performance-collections-taxonomy">
+        <section id="performance-collections-taxonomy">
             <title>Taxonomy</title>
 
             <para>Hibernate defines three basic kinds of collections:</para>
@@ -1180,9 +1180,9 @@
                 collection.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="performance-collections-mostefficientupdate">
+        <section id="performance-collections-mostefficientupdate">
             <title>Lists, maps, idbags and sets are the most efficient collections to update</title>
 
             <para>
@@ -1215,9 +1215,9 @@
                 considerations of collection update performance simply do not apply.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="performance-collections-mostefficentinverse">
+        <section id="performance-collections-mostefficentinverse">
             <title>Bags and lists are the most efficient inverse collections</title>
 
             <para>
@@ -1236,9 +1236,9 @@
 p.getChildren().add(c);  //no need to fetch the collection!
 sess.flush();]]></programlisting>
 
-        </sect2>
+        </section>
 
-        <sect2 id="performance-collections-oneshotdelete">
+        <section id="performance-collections-oneshotdelete">
             <title>One shot delete</title>
 
             <para>
@@ -1285,11 +1285,11 @@
                 One-shot-delete does not apply to collections mapped <literal>inverse="true"</literal>.
             </para>
 
-        </sect2>
+        </section>
 
-    </sect1>
+    </section>
 
-    <sect1 id="performance-monitoring" revision="1">
+    <section id="performance-monitoring" revision="1">
         <title>Monitoring performance</title>
 
         <para>
@@ -1298,7 +1298,7 @@
             Statistics in Hibernate are available per <literal>SessionFactory</literal>.
         </para>
 
-        <sect2 id="performance-monitoring-sf" revision="2">
+        <section id="performance-monitoring-sf" revision="2">
             <title>Monitoring a SessionFactory</title>
 
             <para>
@@ -1364,9 +1364,9 @@
                 method.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="performance-monitoring-metrics" revision="1">
+        <section id="performance-monitoring-metrics" revision="1">
             <title>Metrics</title>
 
             <para>
@@ -1437,8 +1437,8 @@
                 <literal>getSecondLevelCacheRegionNames()</literal>.
             </para>
 
-        </sect2>
+        </section>
 
-    </sect1>
+    </section>
 
 </chapter>

Modified: projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/persistent_classes.xml
===================================================================
--- projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/persistent_classes.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/persistent_classes.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -43,7 +43,7 @@
         ways (using trees of <literal>Map</literal> instances, for example).
     </para>
 
-    <sect1 id="persistent-classes-pojo">
+    <section id="persistent-classes-pojo">
         <title>A simple POJO example</title>
 
         <para>
@@ -134,7 +134,7 @@
         </para>
 
 
-        <sect2 id="persistent-classes-pojo-constructor" revision="1">
+        <section id="persistent-classes-pojo-constructor" revision="1">
             <title>Implement a no-argument constructor</title>
 
             <para>
@@ -144,9 +144,9 @@
                 default constructor with at least <emphasis>package</emphasis> visibility for runtime proxy 
                 generation in Hibernate.
             </para>
-        </sect2>
+        </section>
 
-        <sect2 id="persistent-classes-pojo-identifier" revision="2">
+        <section id="persistent-classes-pojo-identifier" revision="2">
             <title>Provide an identifier property (optional)</title>
 
             <para>
@@ -191,9 +191,9 @@
                 We recommend that you declare consistently-named identifier properties on persistent
                 classes and that you use a nullable (i.e., non-primitive) type.
             </para>
-        </sect2>
+        </section>
 
-        <sect2 id="persistent-classes-pojo-final">
+        <section id="persistent-classes-pojo-final">
             <title>Prefer non-final classes (optional)</title>
             <para>
                 A central feature of Hibernate, <emphasis>proxies</emphasis>, depends upon the
@@ -210,9 +210,9 @@
                 non-final classes. If you want to use a class with a <literal>public final</literal> 
                 method, you must explicitly disable proxying by setting <literal>lazy="false"</literal>.
             </para>
-        </sect2>
+        </section>
         
-        <sect2 id="persistent-classes-pojo-accessors" revision="2">
+        <section id="persistent-classes-pojo-accessors" revision="2">
             <title>Declare accessors and mutators for persistent fields (optional)</title>
 
             <para>
@@ -231,11 +231,11 @@
                 <literal>private</literal> get / set pair.
             </para>
 
-        </sect2>
+        </section>
 
-    </sect1>
+    </section>
 
-    <sect1 id="persistent-classes-inheritance">
+    <section id="persistent-classes-inheritance">
         <title>Implementing inheritance</title>
 
         <para>
@@ -255,9 +255,9 @@
                 this.name=name;
         }
 }]]></programlisting>
-    </sect1>
+    </section>
 
-    <sect1 id="persistent-classes-equalshashcode" revision="1">
+    <section id="persistent-classes-equalshashcode" revision="1">
         <title>Implementing <literal>equals()</literal> and <literal>hashCode()</literal></title>
 
         <para>
@@ -340,9 +340,9 @@
             candidates for a business key.
         </para>
 
-    </sect1>
+    </section>
 
-    <sect1 id="persistent-classes-dynamicmodels">
+    <section id="persistent-classes-dynamicmodels">
         <title>Dynamic models</title>
 
         
@@ -484,9 +484,9 @@
             in <xref linkend="xml"/>.
         </para>
 
-    </sect1>
+    </section>
 
-    <sect1 id="persistent-classes-tuplizers" revision="1">
+    <section id="persistent-classes-tuplizers" revision="1">
         <title>Tuplizers</title>
 
         <para>
@@ -553,10 +553,10 @@
 }]]></programlisting>
 
 
-    </sect1>
+    </section>
 
 
-    <sect1 id="persistent-classes-entity-name-resolver" revision="0">
+    <section id="persistent-classes-entity-name-resolver" revision="0">
         <title>EntityNameResolvers</title>
 
         <para>
@@ -700,14 +700,14 @@
                 </listitem>
             </orderedlist>
         </para>
-    </sect1>
+    </section>
 
-    <!--<sect1 id="persistent-classes-extensions">
+    <!--<section id="persistent-classes-extensions">
         <title>Extensions</title>
         <para>
             TODO: Document user-extension framework in the property and proxy packages
         </para>
-    </sect1>-->
+    </section>-->
 
 </chapter>
 

Modified: projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/query_criteria.xml
===================================================================
--- projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/query_criteria.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/query_criteria.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -32,7 +32,7 @@
         Hibernate features an intuitive, extensible criteria query API.
     </para>
     
-    <sect1 id="querycriteria-creating">
+    <section id="querycriteria-creating">
         <title>Creating a <literal>Criteria</literal> instance</title>
 
         <para>
@@ -45,9 +45,9 @@
 crit.setMaxResults(50);
 List cats = crit.list();]]></programlisting>
 
-    </sect1>
+    </section>
      
-    <sect1 id="querycriteria-narrowing">
+    <section id="querycriteria-narrowing">
         <title>Narrowing the result set</title>
 
         <para>
@@ -117,9 +117,9 @@
     .add( Property.forName("name").in( new String[] { "Fritz", "Izi", "Pk" } ) )
     .list();]]></programlisting>
     
-   </sect1>
+   </section>
      
-    <sect1 id="querycriteria-ordering">
+    <section id="querycriteria-ordering">
         <title>Ordering the results</title>
 
         <para>
@@ -140,9 +140,9 @@
     .setMaxResults(50)
     .list();]]></programlisting>
     
-    </sect1>
+    </section>
     
-    <sect1 id="querycriteria-associations" revision="2">
+    <section id="querycriteria-associations" revision="2">
         <title>Associations</title>
 
         <para>
@@ -196,9 +196,9 @@
     Cat kitten = (Cat) map.get("kt");
 }]]></programlisting>
 
-    </sect1>
+    </section>
     
-    <sect1 id="querycriteria-dynamicfetching" revision="1">
+    <section id="querycriteria-dynamicfetching" revision="1">
         <title>Dynamic association fetching</title>
 
         <para>
@@ -217,9 +217,9 @@
             by outer join. See <xref linkend="performance-fetching"/> for more information.
         </para>
     
-    </sect1>
+    </section>
      
-    <sect1 id="querycriteria-examples">
+    <section id="querycriteria-examples">
         <title>Example queries</title>
 
         <para>
@@ -262,9 +262,9 @@
         .add( Example.create( cat.getMate() ) )
     .list();]]></programlisting>
     
-    </sect1>
+    </section>
     
-    <sect1 id="querycriteria-projection">
+    <section id="querycriteria-projection">
         <title>Projections, aggregation and grouping</title>
         <para>
             The class <literal>org.hibernate.criterion.Projections</literal> is a
@@ -356,9 +356,9 @@
     .addOrder( Order.desc("avgWeight") )
     .list();]]></programlisting>
     
-    </sect1>
+    </section>
     
-    <sect1 id="querycriteria-detachedqueries">
+    <section id="querycriteria-detachedqueries">
         <title>Detached queries and subqueries</title>
         <para>
             The <literal>DetachedCriteria</literal> class allows you to create a query outside the scope 
@@ -403,13 +403,13 @@
     .add( Property.forName("weight").gt(avgWeightForSex) )
     .list();]]></programlisting>
 
-    </sect1>
+    </section>
 
         <!--TODO: ResultSetTransformer + aliasing. AliasToBeanTransformer allow returning arbitrary 
                   user objects - similar to setResultClass in JDO2. General use of ResultTransformer 
                   could also be explained. -->
                
-    <sect1 id="query-criteria-naturalid">
+    <section id="query-criteria-naturalid">
         <title>Queries by natural identifier</title>
         
         <para>
@@ -455,6 +455,6 @@
     ).setCacheable(true)
     .uniqueResult();]]></programlisting>
             
-    </sect1>
+    </section>
     
 </chapter>

Modified: projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/query_sql.xml
===================================================================
--- projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/query_sql.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/query_sql.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -37,7 +37,7 @@
   <para>Hibernate3 allows you to specify handwritten SQL, including stored
   procedures, for all create, update, delete, and load operations.</para>
 
-  <sect1 id="querysql-creating" revision="4">
+  <section id="querysql-creating" revision="4">
     <title>Using a <literal>SQLQuery</literal></title>
 
     <para>Execution of native SQL queries is controlled via the
@@ -45,7 +45,7 @@
     <literal>Session.createSQLQuery()</literal>. The following sections describe how
     to use this API for querying.</para>
 
-    <sect2>
+    <section>
       <title>Scalar queries</title>
 
       <para>The most basic SQL query is to get a list of scalars
@@ -108,9 +108,9 @@
       not mapped, or does not result in the expected type, it is possible to
       customize it via calls to <literal>registerHibernateType</literal> in
       the Dialect.</para>
-    </sect2>
+    </section>
 
-    <sect2>
+    <section>
       <title>Entity queries</title>
 
       <para>The above queries were all about returning scalar values,
@@ -150,9 +150,9 @@
 ]]></programlisting>
 
       <para>This will allow cat.getDog() to function properly.</para>
-    </sect2>
+    </section>
 
-    <sect2>
+    <section>
       <title>Handling associations and collections</title>
 
       <para>It is possible to eagerly join in the <literal>Dog</literal> to
@@ -183,9 +183,9 @@
             enhance the sql queries to make them usable in Hibernate. Problems can arise when returning
             multiple entities of the same type or when the default alias/column names are not enough.
         </para>
-    </sect2>
+    </section>
 
-    <sect2>
+    <section>
       <title>Returning multiple entities</title>
 
       <para>Until now, the result set column names are assumed to be the same
@@ -251,7 +251,7 @@
         .addEntity("mother", Cat.class).list()
 ]]></programlisting>
 
-      <sect3 id="querysql-aliasreferences" revision="2">
+      <section id="querysql-aliasreferences" revision="2">
         <title>Alias and property references</title>
 
         <para>In most cases the above alias injection is needed. For
@@ -368,10 +368,10 @@
             </tbody>
           </tgroup>
         </table>
-      </sect3>
-    </sect2>
+      </section>
+    </section>
 
-    <sect2>
+    <section>
       <title>Returning non-managed entities</title>
 
       <para>It is possible to apply a ResultTransformer to native SQL queries, allowing it to return non-managed entities.</para>
@@ -395,17 +395,17 @@
         The above query will return a list of <literal>CatDTO</literal> which has been instantiated and injected the values of NAME and BIRTHNAME into its corresponding
         properties or fields.
         </para>
-    </sect2>
+    </section>
 
-    <sect2>
+    <section>
       <title>Handling inheritance</title>
 
       <para>Native SQL queries which query for entities that are mapped as part
       of an inheritance must include all properties for the baseclass and all
       its subclasses.</para>
-    </sect2>
+    </section>
 
-    <sect2>
+    <section>
       <title>Parameters</title>
 
       <para>Native SQL queries support positional as well as named
@@ -416,13 +416,13 @@
      
 query = sess.createSQLQuery("SELECT * FROM CATS WHERE NAME like :name").addEntity(Cat.class);
 List pusList = query.setString("name", "Pus%").list();          ]]></programlisting>
-    </sect2>
+    </section>
     
     
         
-  </sect1>
+  </section>
 
-  <sect1 id="querysql-namedqueries" revision="3">
+  <section id="querysql-namedqueries" revision="3">
     <title>Named SQL queries</title>
 
     <para>Named SQL queries can be defined in the mapping document and called
@@ -509,7 +509,7 @@
     .setResultSetMapping("catAndKitten")
     .list();]]></programlisting>
 
-    <sect2 id="propertyresults">
+    <section id="propertyresults">
       <title>Using return-property to explicitly specify column/alias
       names</title>
 
@@ -560,9 +560,9 @@
       <para>If your mapping has a discriminator you must use
       <literal>&lt;return-discriminator&gt;</literal> to specify the
       discriminator column.</para>
-    </sect2>
+    </section>
 
-    <sect2 id="sp_query" revision="1">
+    <section id="sp_query" revision="1">
       <title>Using stored procedures for querying</title>
 
       <para>Hibernate3 provides support for queries via stored procedures
@@ -607,7 +607,7 @@
       entities. <literal>&lt;return-join&gt;</literal> and
       <literal>&lt;load-collection&gt;</literal> are not supported.</para>
 
-      <sect3 id="querysql-limits-storedprocedures" revision="1">
+      <section id="querysql-limits-storedprocedures" revision="1">
         <title>Rules/limitations for using stored procedures</title>
 
         <para>You cannot use stored procedures with Hibernate unless you follow some procedure/function
@@ -655,11 +655,11 @@
             requirement.</para>
           </listitem>
         </itemizedlist>
-      </sect3>
-    </sect2>
-  </sect1>
+      </section>
+    </section>
+  </section>
 
-  <sect1 id="querysql-cud">
+  <section id="querysql-cud">
     <title>Custom SQL for create, update and delete</title>
 
     <para>Hibernate3 can use custom SQL statements for create, update, and
@@ -726,9 +726,9 @@
     return SQL%ROWCOUNT;
 
 END updatePerson;]]></programlisting>
-  </sect1>
+  </section>
 
-  <sect1 id="querysql-load">
+  <section id="querysql-load">
     <title>Custom SQL for loading</title>
 
     <para>You can also declare your own SQL (or HQL) queries for entity
@@ -783,5 +783,5 @@
         ON pers.ID = emp.PERSON_ID
     WHERE ID=?
 </sql-query>]]></programlisting>
-  </sect1>
+  </section>
 </chapter>

Modified: projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/tutorial.xml
===================================================================
--- projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/tutorial.xml	2009-12-09 06:48:38 UTC (rev 97593)
+++ projects/docs/enterprise/EWP_5.0/Hibernate/Hibernate_Core/en-US/tutorial.xml	2009-12-09 07:01:20 UTC (rev 97594)
@@ -55,7 +55,7 @@
         </para>
     </note>
 
-    <sect1 id="tutorial-firstapp">
+    <section id="tutorial-firstapp">
         <title>Part 1 - The first Hibernate Application</title>
 
         <para>
@@ -72,7 +72,7 @@
             </para>
         </note>
 
-        <sect2 id="tutorial-firstapp-setup">
+        <section id="tutorial-firstapp-setup">
             <title>Setup</title>
 
             <para>
@@ -185,10 +185,10 @@
             <para>
                 Save this file as <filename>pom.xml</filename> in the project root directory.
             </para>
-        </sect2>
+        </section>
 
 
-        <sect2 id="tutorial-firstapp-firstclass">
+        <section id="tutorial-firstapp-firstclass">
             <title>The first class</title>
             
             <para>
@@ -268,9 +268,9 @@
                 Save this file to the <filename>src/main/java/org/hibernate/tutorial/domain</filename>
                 directory.
             </para>
-        </sect2>
+        </section>
 
-        <sect2 id="tutorial-firstapp-mapping">
+        <section id="tutorial-firstapp-mapping">
             <title>The mapping file</title>
 
             <para>
@@ -444,9 +444,9 @@
                 <filename>src/main/resources/org/hibernate/tutorial/domain/Event.hbm.xml</filename>.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="tutorial-firstapp-configuration" revision="2">
+        <section id="tutorial-firstapp-configuration" revision="2">
             <title>Hibernate configuration</title>
 
             <para>
@@ -571,9 +571,9 @@
                 <filename>src/main/resources</filename> directory.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="tutorial-firstapp-mvn" revision="1">
+        <section id="tutorial-firstapp-mvn" revision="1">
             <title>Building with Maven</title>
 
             <para>
@@ -604,9 +604,9 @@
 [INFO] Final Memory: 5M/547M
 [INFO] ------------------------------------------------------------------------]]></programlisting>
 
-        </sect2>
+        </section>
 
-        <sect2 id="tutorial-firstapp-helpers" revision="3">
+        <section id="tutorial-firstapp-helpers" revision="3">
             <title>Startup and helpers</title>
 
             <para>
@@ -694,9 +694,9 @@
                 Hibernate.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="tutorial-firstapp-workingpersistence" revision="5">
+        <section id="tutorial-firstapp-workingpersistence" revision="5">
             <title>Loading and storing objects</title>
 
             <para>
@@ -884,11 +884,11 @@
                 <command>mvn exec:java -Dexec.mainClass="org.hibernate.tutorial.EventManager" -Dexec.args="list"</command>
             </para>
 
-        </sect2>
+        </section>
 
-    </sect1>
+    </section>
 
-    <sect1 id="tutorial-associations">
+    <section id="tutorial-associations">
         <title>Part 2 - Mapping associations</title>
 
         <para>
@@ -898,7 +898,7 @@
             which they participate.
         </para>
 
-        <sect2 id="tutorial-associations-mappinguser" revision="1">
+        <section id="tutorial-associations-mappinguser" revision="1">
             <title>Mapping the Person class</title>
 
             <para>
@@ -957,9 +957,9 @@
                 behavior.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="tutorial-associations-unidirset" revision="3">
+        <section id="tutorial-associations-unidirset" revision="3">
             <title>A unidirectional Set-based association</title>
 
             <para>
@@ -1048,9 +1048,9 @@
                                                   |_____________|
  ]]></programlisting>
 
-        </sect2>
+        </section>
 
-        <sect2 id="tutorial-associations-working" revision="2">
+        <section id="tutorial-associations-working" revision="2">
             <title>Working the association</title>
 
             <para>
@@ -1169,9 +1169,9 @@
                 entities, but looks almost the same in Java.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="tutorial-associations-valuecollections">
+        <section id="tutorial-associations-valuecollections">
             <title>Collection of values</title>
 
             <para>
@@ -1261,9 +1261,9 @@
                 optimize this with an eager fetch.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="tutorial-associations-bidirectional" revision="1">
+        <section id="tutorial-associations-bidirectional" revision="1">
             <title>Bi-directional associations</title>
 
             <para>
@@ -1322,9 +1322,9 @@
                 understand once you see how the bi-directional link between our two entities is created.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="tutorial-associations-usingbidir">
+        <section id="tutorial-associations-usingbidir">
             <title>Working bi-directional links</title>
 
             <para>
@@ -1378,11 +1378,11 @@
                 and in many-to-many association you can select either side.
             </para>
 
-        </sect2>
+        </section>
 
-    </sect1>
+    </section>
 
-    <sect1 id="tutorial-webapp">
+    <section id="tutorial-webapp">
         <title>Part 3 - The EventManager web application</title>
 
         <para>
@@ -1392,7 +1392,7 @@
             database, and it provides an HTML form to enter new events.
         </para>
 
-        <sect2 id="tutorial-webapp-servlet" revision="2">
+        <section id="tutorial-webapp-servlet" revision="2">
             <title>Writing the basic servlet</title>
 
             <para>
@@ -1472,9 +1472,9 @@
                 as you consider rendering your view in JSP, not in a servlet.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="tutorial-webapp-processing" revision="1">
+        <section id="tutorial-webapp-processing" revision="1">
             <title>Processing and rendering</title>
 
             <para>
@@ -1582,9 +1582,9 @@
                 examples.
             </para>
 
-        </sect2>
+        </section>
 
-        <sect2 id="tutorial-webapp-deploy">
+        <section id="tutorial-webapp-deploy">
             <title>Deploying and testing</title>
 
             <para>
@@ -1632,11 +1632,11 @@
                 is called) and to get the detailed output if any exceptions occurs.
             </para>
 
-        </sect2>
+        </section>
 
-    </sect1>
+    </section>
 
-    <sect1 id="tutorial-summary" revision="1">
+    <section id="tutorial-summary" revision="1">
         <title>Summary</title>
 
         <para>
@@ -1645,6 +1645,6 @@
             <ulink url="http://hibernate.org">website</ulink>.
         </para>
 
-    </sect1>
+    </section>
 
 </chapter>




More information about the jboss-cvs-commits mailing list