KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > sapia > regis > RegisSession


1 package org.sapia.regis;
2
3 /**
4  * An instance of this class must be acquired from a <code>Registry</code> when
5  * performing operations on that registry, or on any one of its nodes.
6  * <p>
7  * An instance of this class is not thread-safe. It must be used in the context
8  * of a single thread, and it must be closed once the thread as completed a unit
9  * of work.
10  * <p>
11  * <i>Working with an instance of this class is similar to working with an Hibernate
12  * session.</i>
13  *
14  * @author yduchesne
15  *
16  */

17 public interface RegisSession {
18   
19   /**
20    * This method closes this instance (destroying any system resources
21    * and releasing any objects that this instance may hold)
22    */

23   public void close();
24   
25   /**
26    * @param node a <code>Node</code>
27    * @return a <code>Node</code>, corresponding to the given node, but
28    * "attached" to this session.
29    */

30   public Node attach(Node node);
31
32 }
33
Popular Tags