KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jfox > ejb > EJBPoolableObject


1 /* JFox, the OpenSource J2EE Application Server
2  *
3  * Distributable under GNU LGPL license by gun.org
4  * more details please visit http://www.huihoo.org/jfox
5  */

6
7 package org.jfox.ejb;
8
9 import javax.ejb.EnterpriseBean JavaDoc;
10
11 import org.jfox.pool.AbstractPoolableObject;
12
13 /**
14  * 封装一个 EJBObject Bean instance , 使其可以被缓存到 ObjectPool 中
15  *
16  * @author <a HREF="mailto:young_yy@hotmail.com">Young Yang</a>
17  */

18
19 public class EJBPoolableObject extends AbstractPoolableObject {
20     private EnterpriseBean JavaDoc instance = null;
21
22     public EJBPoolableObject() {
23     }
24
25 /*
26     public EJBPoolableObject(EnterpriseBean instance) {
27         super();
28         this.instance = instance;
29     }
30 */

31
32     void setBeanInstance(EnterpriseBean JavaDoc bean) {
33         this.instance = bean;
34     }
35
36     public EnterpriseBean JavaDoc getBeanInstance() {
37         return instance;
38     }
39
40     public void activate() throws Exception JavaDoc {
41         super.activate();
42     }
43
44     public void passivate() throws Exception JavaDoc {
45         super.passivate();
46     }
47
48     public static void main(String JavaDoc[] args) {
49
50     }
51 }
52
Popular Tags