KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tc > object > bytecode > Manager


1 /*
2  * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright
3  * notice. All rights reserved.
4  */

5 package com.tc.object.bytecode;
6
7 import com.tc.cluster.ClusterEventListener;
8 import com.tc.logging.TCLogger;
9 import com.tc.management.beans.sessions.SessionMonitorMBean;
10 import com.tc.object.ObjectID;
11 import com.tc.object.TCObject;
12 import com.tc.object.event.DmiManager;
13 import com.tc.object.lockmanager.api.LockLevel;
14 import com.tc.properties.TCProperties;
15
16 /**
17  * The Manager interface
18  */

19 public interface Manager {
20
21   public static final String JavaDoc CLASS = "com/tc/object/bytecode/Manager";
22   public static final String JavaDoc TYPE = "L" + CLASS + ";";
23
24   public final static int LOCK_TYPE_READ = LockLevel.READ;
25   public final static int LOCK_TYPE_WRITE = LockLevel.WRITE;
26   public final static int LOCK_TYPE_CONCURRENT = LockLevel.CONCURRENT;
27   public final static int LOCK_TYPE_SYNCHRONOUS_WRITE = LockLevel.SYNCHRONOUS_WRITE;
28
29   public boolean isPhysicallyInstrumented(Class JavaDoc clazz);
30
31   public Object JavaDoc deepCopy(Object JavaDoc source);
32
33   public void init();
34
35   public void stop();
36
37   public Object JavaDoc lookupOrCreateRoot(String JavaDoc name, Object JavaDoc object);
38
39   public Object JavaDoc lookupOrCreateRootNoDepth(String JavaDoc name, Object JavaDoc obj);
40
41   public Object JavaDoc createOrReplaceRoot(String JavaDoc rootName, Object JavaDoc object);
42
43   public void beginVolatile(TCObject tcObject, String JavaDoc fieldName, int type);
44
45   public void beginLock(String JavaDoc lockID, int type);
46
47   public boolean tryBeginLock(String JavaDoc lockID, int type);
48
49   public void commitVolatile(TCObject tcObject, String JavaDoc fieldName);
50
51   public void commitLock(String JavaDoc lockName);
52
53   public Object JavaDoc lookupObject(ObjectID id) throws ClassNotFoundException JavaDoc;
54
55   public TCObject lookupExistingOrNull(Object JavaDoc obj);
56
57   public TCObject lookupOrCreate(Object JavaDoc obj);
58
59   public TCObject shareObjectIfNecessary(Object JavaDoc pojo);
60
61   public void objectNotify(Object JavaDoc obj);
62
63   public void objectNotifyAll(Object JavaDoc obj);
64
65   public void objectWait0(Object JavaDoc obj) throws InterruptedException JavaDoc;
66
67   public void objectWait1(Object JavaDoc obj, long millis) throws InterruptedException JavaDoc;
68
69   public void objectWait2(Object JavaDoc obj, long millis, int nanos) throws InterruptedException JavaDoc;
70
71   public void monitorEnter(Object JavaDoc obj, int type);
72
73   public void monitorExit(Object JavaDoc obj);
74
75   public void logicalInvoke(Object JavaDoc object, String JavaDoc methodName, Object JavaDoc[] params);
76
77   public void logicalInvokeWithTransaction(Object JavaDoc object, Object JavaDoc lockObject, String JavaDoc methodName, Object JavaDoc[] params);
78
79   public boolean distributedMethodCall(Object JavaDoc receiver, String JavaDoc method, Object JavaDoc[] params, boolean runOnAllNodes);
80
81   public void distributedMethodCallCommit();
82
83   public Object JavaDoc lookupRoot(String JavaDoc name);
84
85   public void checkWriteAccess(Object JavaDoc context);
86
87   public boolean isManaged(Object JavaDoc object);
88
89   public boolean isLogical(Object JavaDoc object);
90
91   public boolean isRoot(String JavaDoc className, String JavaDoc fieldName);
92
93   public void optimisticBegin();
94
95   public void optimisticCommit() throws ClassNotFoundException JavaDoc;
96
97   public void optimisticRollback();
98
99   public boolean isLocked(Object JavaDoc obj);
100
101   public boolean tryMonitorEnter(Object JavaDoc obj, int type);
102
103   public boolean isHeldByCurrentThread(Object JavaDoc obj, int lockLevel);
104
105   public int queueLength(Object JavaDoc obj);
106
107   public int waitLength(Object JavaDoc obj);
108
109   public boolean isCreationInProgress();
110
111   public String JavaDoc getClientID();
112
113   public TCLogger getLogger(String JavaDoc loggerName);
114
115   public SessionMonitorMBean getSessionMonitorMBean();
116
117   public TCProperties getTCProperites();
118
119   public void addClusterEventListener(ClusterEventListener cel);
120
121   public DmiManager getDmiManager();
122
123 }
124
Popular Tags