KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jgroups > jmx > JChannelMBean


1 package org.jgroups.jmx;
2
3 import org.jgroups.*;
4 import org.w3c.dom.Element JavaDoc;
5
6 import java.io.Serializable JavaDoc;
7 import java.util.Map JavaDoc;
8
9 /**
10  * @author Bela Ban
11  * @version $Id: JChannelMBean.java,v 1.11 2007/02/16 07:32:10 belaban Exp $
12  */

13 public interface JChannelMBean {
14     void create() throws Exception JavaDoc;
15     void start() throws Exception JavaDoc;
16     void stop();
17     void destroy();
18
19     //void jbossInternalLifecycle(String method) throws Exception;
20
org.jgroups.JChannel getChannel();
21
22     String JavaDoc getProperties();
23     void setProperties(String JavaDoc props);
24
25     String JavaDoc getVersion();
26
27     String JavaDoc getObjectName();
28     void setObjectName(String JavaDoc name);
29
30     int getNumberOfTasksInTimer();
31     String JavaDoc dumpTimerQueue();
32     int getTimerThreads();
33
34     /** To configure via XML file */
35     void setClusterConfig(Element JavaDoc el);
36
37     String JavaDoc getGroupName();
38     void setGroupName(String JavaDoc group_name);
39
40     String JavaDoc getClusterName();
41     void setClusterName(String JavaDoc cluster_name);
42
43     boolean getReceiveBlockEvents();
44     void setReceiveBlockEvents(boolean flag);
45
46     boolean getReceiveLocalMessages();
47     void setReceiveLocalMessages(boolean flag);
48
49     boolean getAutoReconnect();
50     void setAutoReconnect(boolean flag);
51
52     boolean getAutoGetState();
53     void setAutoGetState(boolean flag);
54
55     Map JavaDoc dumpStats();
56
57     View getView();
58     String JavaDoc getViewAsString();
59     Address getLocalAddress();
60     String JavaDoc getLocalAddressAsString();
61     void setChannelListener(ChannelListener channel_listener);
62     boolean getStatsEnabled();
63     void setStatsEnabled(boolean flag);
64     void resetStats();
65     long getSentMessages();
66     long getSentBytes();
67     long getReceivedMessages();
68     long getReceivedBytes();
69
70     boolean isOpen();
71
72     boolean isConnected();
73
74     int getNumMessages();
75
76     String JavaDoc dumpQueue();
77
78     String JavaDoc printProtocolSpec(boolean include_properties);
79
80     String JavaDoc toString(boolean print_details);
81
82     void connect(String JavaDoc channel_name) throws ChannelException, ChannelClosedException;
83
84     void disconnect();
85
86     void close();
87
88     void shutdown();
89
90     void send(Message msg) throws ChannelNotConnectedException, ChannelClosedException;
91
92     void send(Address dst, Address src, Serializable JavaDoc obj) throws ChannelNotConnectedException, ChannelClosedException;
93
94     void sendToAll(String JavaDoc msg) throws ChannelNotConnectedException, ChannelClosedException;
95
96     /** @param evt
97      * @deprecated */

98     void down(Event evt);
99
100     Object JavaDoc receive(long timeout) throws ChannelNotConnectedException, ChannelClosedException, TimeoutException;
101
102     Object JavaDoc peek(long timeout) throws ChannelNotConnectedException, ChannelClosedException, TimeoutException;
103
104     void blockOk();
105
106     boolean getState(Address target, long timeout) throws ChannelNotConnectedException, ChannelClosedException;
107
108     void returnState(byte[] state);
109
110     void returnState(byte[] state, String JavaDoc state_id);
111 }
112
Popular Tags