KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tc > object > tx > ClientTransaction


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

4 package com.tc.object.tx;
5
6 import com.tc.management.beans.tx.ClientTxMonitorMBean;
7 import com.tc.object.ObjectID;
8 import com.tc.object.TCObject;
9 import com.tc.object.dmi.DmiDescriptor;
10 import com.tc.object.lockmanager.api.LockID;
11 import com.tc.object.lockmanager.api.Notify;
12 import com.tc.util.SequenceID;
13
14 import java.util.Collection JavaDoc;
15 import java.util.List JavaDoc;
16 import java.util.Map JavaDoc;
17
18 /**
19  * Hangs on to a grouping of changes to be sent as a batch to the server
20  *
21  * @author steve
22  */

23 public interface ClientTransaction {
24
25   public void setTransactionContext(TransactionContext transactionContext);
26
27   public Map JavaDoc getChangeBuffers();
28
29   public Map JavaDoc getNewRoots();
30
31   public LockID getLockID();
32
33   public LockID[] getAllLockIDs();
34
35   public TransactionID getTransactionID();
36
37   public void createObject(TCObject source);
38
39   public void createRoot(String JavaDoc name, ObjectID rootID);
40
41   public void fieldChanged(TCObject source, String JavaDoc classname, String JavaDoc fieldname, Object JavaDoc newValue, int index);
42
43   public void literalValueChanged(TCObject source, Object JavaDoc newValue, Object JavaDoc oldValue);
44
45   public void arrayChanged(TCObject source, int startPos, Object JavaDoc array, int length);
46
47   public void logicalInvoke(TCObject source, int method, Object JavaDoc[] parameters, String JavaDoc methodName);
48
49   public boolean hasChangesOrNotifies();
50
51   public boolean isNull();
52
53   public TxnType getTransactionType();
54
55   public List JavaDoc addNotifiesTo(List JavaDoc notifies);
56
57   public void addNotify(Notify notify);
58
59   public void setSequenceID(SequenceID sequenceID);
60
61   public SequenceID getSequenceID();
62
63   public boolean isConcurrent();
64
65   public void setAlreadyCommitted();
66
67   public boolean hasChanges();
68
69   public int getNotifiesCount();
70
71   public void updateMBean(ClientTxMonitorMBean txMBean);
72
73   public Collection JavaDoc getReferencesOfObjectsInTxn();
74   
75   public void addDmiDescritor(DmiDescriptor dd);
76   
77   public List JavaDoc getDmiDescriptors();
78
79 }
80
Popular Tags