Update of /cvsroot/hibernate/Hibernate2/src/net/sf/hibernate
In directory sc8-pr-cvs1:/tmp/cvs-serv24602/hibernate
Modified Files:
Hibernate.java Session.java
Log Message:
* SessionFactory.close() now unbinds from JNDI
* added Session.remove()
* got rid of another unnecessry collection delete()
Index: Hibernate.java
===================================================================
RCS file: /cvsroot/hibernate/Hibernate2/src/net/sf/hibernate/Hibernate.java,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** Hibernate.java 11 Apr 2003 07:15:50 -0000 1.11
--- Hibernate.java 19 Apr 2003 03:26:06 -0000 1.12
***************
*** 246,249 ****
--- 246,265 ----
/**
+ * Get the true, underlying class of a proxied persistent class. This operation
+ * will initialize a proxy by side-effect.
+ * @param proxy a persistable object or proxy
+ * @return the true class of the instance
+ * @throws HibernateException
+ */
+ public Class getClass(Object proxy) throws HibernateException {
+ if (proxy instanceof HibernateProxy) {
+ return HibernateProxyHelper.getLazyInitializer( (HibernateProxy) proxy ).getImplementation().getClass();
+ }
+ else {
+ return proxy.getClass();
+ }
+ }
+
+ /**
* Create a new <tt>Blob</tt>. The returned object will be
* initially immutable.
Index: Session.java
===================================================================
RCS file: /cvsroot/hibernate/Hibernate2/src/net/sf/hibernate/Session.java,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -d -r1.14 -r1.15
*** Session.java 29 Mar 2003 04:08:46 -0000 1.14
--- Session.java 19 Apr 2003 03:26:06 -0000 1.15
***************
*** 175,178 ****
--- 175,185 ----
*/
public boolean contains(Object object);
+ /**
+ * Remove this instance from the session cache. Changes to the instance will
+ * not be synchronized with the database.
+ *
+ * @param object a persistent instance
+ */
+ public void remove(Object object) throws HibernateException;
/**
|