KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > objectweb > joram > shared > admin > SetCluster


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

24 package org.objectweb.joram.shared.admin;
25
26 /**
27  * A <code>SetCluster</code> instance is used for adding a given topic
28  * to a cluster an other topic is part of, or for creating a new cluster.
29  */

30 public class SetCluster extends AdminRequest {
31   private static final long serialVersionUID = 3888475137454407781L;
32
33   /**
34    * Identifier of the topic already part of a cluster, or chosen as the
35    * initiator.
36    */

37   private String JavaDoc initId;
38   /** Identifier of the topic joining the cluster, or the initiator. */
39   private String JavaDoc topId;
40
41   /**
42    * Constructs a <code>SetCluster</code> instance.
43    *
44    * @param initName Identifier of the topic already part of a cluster, or
45    * chosen as the initiator.
46    * @param topName Identifier of the topic joining the cluster, or the
47    * initiator.
48    */

49   public SetCluster(String JavaDoc initId, String JavaDoc topId) {
50     this.initId = initId;
51     this.topId = topId;
52   }
53
54   /**
55    * Returns the identifier of the topic already part of a cluster, or chosen
56    * as the initiator.
57    */

58   public String JavaDoc getInitId() {
59     return initId;
60   }
61
62   /**
63    * Returns the identifier of the topic joining the cluster, or the
64    * initiator.
65    */

66   public String JavaDoc getTopId() {
67     return topId;
68   }
69 }
70
Popular Tags