KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tc > objectserver > tx > TestServerTransaction


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.objectserver.tx;
6
7 import com.tc.exception.ImplementMe;
8 import com.tc.net.protocol.tcm.ChannelID;
9 import com.tc.object.dmi.DmiDescriptor;
10 import com.tc.object.dna.impl.ObjectStringSerializer;
11 import com.tc.object.lockmanager.api.LockID;
12 import com.tc.object.tx.ServerTransactionID;
13 import com.tc.object.tx.TransactionID;
14 import com.tc.object.tx.TxnBatchID;
15 import com.tc.object.tx.TxnType;
16 import com.tc.util.SequenceID;
17
18 import java.util.ArrayList JavaDoc;
19 import java.util.Collection JavaDoc;
20 import java.util.Collections JavaDoc;
21 import java.util.List JavaDoc;
22 import java.util.Map JavaDoc;
23 import java.util.Set JavaDoc;
24
25 public final class TestServerTransaction implements ServerTransaction {
26
27   public List JavaDoc changes = new ArrayList JavaDoc();
28   private ServerTransactionID sid;
29   private TxnBatchID bid;
30
31   public TestServerTransaction(ServerTransactionID sid, TxnBatchID bid) {
32     this.sid = sid;
33     this.bid = bid;
34   }
35
36   public ObjectStringSerializer getSerializer() {
37     throw new ImplementMe();
38   }
39
40   public LockID[] getLockIDs() {
41     throw new ImplementMe();
42   }
43
44   public ChannelID getChannelID() {
45     return sid.getChannelID();
46   }
47
48   public TransactionID getTransactionID() {
49     return sid.getClientTransactionID();
50   }
51
52   public SequenceID getClientSequenceID() {
53     throw new ImplementMe();
54   }
55
56   public List JavaDoc getChanges() {
57     return changes;
58   }
59
60   public Map JavaDoc getNewRoots() {
61     return Collections.EMPTY_MAP;
62   }
63
64   public TxnType getTransactionType() {
65     throw new ImplementMe();
66   }
67
68   public Collection JavaDoc getObjectIDs() {
69     throw new ImplementMe();
70   }
71
72   public Collection JavaDoc addNotifiesTo(List JavaDoc list) {
73     return list;
74   }
75
76   public ServerTransactionID getServerTransactionID() {
77     return sid;
78   }
79
80   public TxnBatchID getBatchID() {
81     return bid;
82   }
83
84   public DmiDescriptor[] getDmiDescriptors() {
85     throw new ImplementMe();
86   }
87
88   public boolean isPassive() {
89     return false;
90   }
91
92   public Set JavaDoc getNewObjectIDs() {
93     throw new ImplementMe();
94   }
95
96 }
Popular Tags