KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jgroups > util > ExposedDataOutputStream


1 package org.jgroups.util;
2
3 import java.io.DataOutputStream JavaDoc;
4 import java.io.OutputStream JavaDoc;
5
6 /**
7  * @author Bela Ban
8  * @version $Id: ExposedDataOutputStream.java,v 1.2 2007/01/07 01:25:25 belaban Exp $
9  */

10 public class ExposedDataOutputStream extends DataOutputStream JavaDoc {
11     /**
12      * Creates a new data output stream to write data to the specified
13      * underlying output stream. The counter <code>written</code> is
14      * set to zero.
15      *
16      * @param out the underlying output stream, to be saved for later
17      * use.
18      * @see java.io.FilterOutputStream#out
19      */

20     public ExposedDataOutputStream(OutputStream JavaDoc out) {
21         super(out);
22     }
23
24     public void reset() {
25         written=0;
26     }
27
28     public OutputStream JavaDoc getOutputStream() {
29         return out;
30     }
31 }
32
Popular Tags