KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > objectweb > joram > client > jms > XidImpl


1 /*
2  * JORAM: Java(TM) Open Reliable Asynchronous Messaging
3  * Copyright (C) 2004 - Bull SA
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Lesser General Public
7  * License as published by the Free Software Foundation; either
8  * version 2.1 of the License, or any later version.
9  *
10  * This library is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  * Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public
16  * License along with this library; if not, write to the Free Software
17  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
18  * USA.
19  *
20  * Initial developer(s): Frederic Maistre (Bull SA)
21  * Contributor(s):
22  */

23 package org.objectweb.joram.client.jms;
24
25 /**
26  * Implements the <code>javax.transaction.xa.Xid</code> interface for
27  * identifying distributed transactions.
28  */

29 public class XidImpl implements javax.transaction.xa.Xid JavaDoc
30 {
31   public byte[] branchQualifier;
32   public int formatId;
33   public byte[] globalTransactionId;
34
35
36   /** Constructs a <code>XidImpl</code> instance. */
37   public XidImpl(byte[] branchQualifier,
38                  int formatId,
39                  byte[] globalTransactionId)
40   {
41     this.branchQualifier = branchQualifier;
42     this.formatId = formatId;
43     this.globalTransactionId = globalTransactionId;
44   }
45
46
47   public byte[] getBranchQualifier()
48   {
49     return branchQualifier;
50   }
51
52   public int getFormatId()
53   {
54     return formatId;
55   }
56
57   public byte[] getGlobalTransactionId()
58   {
59     return globalTransactionId;
60   }
61 }
62
Popular Tags