KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jgroups > jmx > protocols > pbcast > FLUSH


1 package org.jgroups.jmx.protocols.pbcast;
2
3 import org.jgroups.jmx.Protocol;
4
5 /**
6  * @author Vladimir Blagojevic
7  * @version $Id$
8  */

9 public class FLUSH extends Protocol implements FLUSHMBean {
10     org.jgroups.protocols.pbcast.FLUSH p;
11
12     public FLUSH() {
13     }
14
15     public FLUSH(org.jgroups.stack.Protocol p) {
16         super(p);
17         this.p=(org.jgroups.protocols.pbcast.FLUSH)p;
18     }
19
20     public void attachProtocol(org.jgroups.stack.Protocol p) {
21         super.attachProtocol(p);
22         this.p=(org.jgroups.protocols.pbcast.FLUSH)p;
23     }
24
25     public double getAverageFlushDuration() {
26         return p.getAverageFlushDuration();
27     }
28
29     public long getTotalTimeInFlush() {
30         return p.getTotalTimeInFlush();
31     }
32
33     public int getNumberOfFlushes() {
34         return p.getNumberOfFlushes();
35     }
36
37     public boolean startFlush(long timeout) {
38         return p.startFlush(timeout);
39     }
40
41     public void stopFlush() {
42         p.stopFlush();
43     }
44 }
45
Popular Tags