KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jgroups > protocols > TRACE


1 // $Id: TRACE.java,v 1.2 2004/03/30 06:47:21 belaban Exp $
2

3 package org.jgroups.protocols;
4 import org.jgroups.Event;
5 import org.jgroups.stack.Protocol;
6
7
8
9 public class TRACE extends Protocol {
10
11     public TRACE() {}
12
13     public String JavaDoc getName() {return "TRACE";}
14
15     
16
17     public void up(Event evt) {
18     System.out.println("---------------- TRACE (received) ----------------------");
19     System.out.println(evt);
20     System.out.println("--------------------------------------------------------");
21     passUp(evt);
22     }
23
24
25     public void down(Event evt) {
26     System.out.println("------------------- TRACE (sent) -----------------------");
27     System.out.println(evt);
28     System.out.println("--------------------------------------------------------");
29     passDown(evt);
30     }
31
32
33     public String JavaDoc toString() {
34     return "Protocol TRACE";
35     }
36
37
38 }
39
Popular Tags