org.sapia.regis.hibernate
Class HibernateRegistryFactory

java.lang.Object
  extended by org.sapia.regis.hibernate.HibernateRegistryFactory
All Implemented Interfaces:
RegistryFactory

public class HibernateRegistryFactory
extends Object
implements RegistryFactory

An instance of this class creates an HibernateRegistry instance.

Author:
yduchesne

Nested Class Summary
static class HibernateRegistryFactory.HibernateConfigContext
           
 
Constructor Summary
HibernateRegistryFactory()
           
 
Method Summary
 Registry connect(Properties props)
          This method expects properties that follow the Hibernate configuration spec.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HibernateRegistryFactory

public HibernateRegistryFactory()
Method Detail

connect

public Registry connect(Properties props)
                 throws Exception
This method expects properties that follow the Hibernate configuration spec. The properties are simply delegated to an Hibernate Configuration object.

The returned Registry implementation will thus be based on an Hibernate SessionFactory.

Specified by:
connect in interface RegistryFactory
Parameters:
props - some Hibernate properties.
Returns:
an HibernateRegistry instance.
Throws:
Exception - if a problem occurs while attempting to connect.


Copyright © 2006 Sapia Open Community, Inc. All Rights Reserved.