KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > gjt > jclasslib > io > ByteCodeOutputStream


1 /*
2     This library is free software; you can redistribute it and/or
3     modify it under the terms of the GNU General Public
4     License as published by the Free Software Foundation; either
5     version 2 of the license, or (at your option) any later version.
6 */

7
8 package org.gjt.jclasslib.io;
9
10 import java.io.DataOutputStream JavaDoc;
11 import java.io.OutputStream JavaDoc;
12
13 /**
14     <tt>DataOutputStream</tt> which extends <tt>ByteCodeOutput</tt>.
15  
16     @author <a HREF="mailto:jclasslib@ej-technologies.com">Ingo Kegel</a>
17     @version $Revision: 1.4 $ $Date: 2003/08/18 07:58:12 $
18 */

19 public class ByteCodeOutputStream extends DataOutputStream JavaDoc
20                                   implements ByteCodeOutput
21 {
22
23     /**
24         Constructor.
25         @param out the output stream.
26      */

27     public ByteCodeOutputStream(OutputStream JavaDoc out) {
28         super(new CountedOutputStream(out));
29     }
30     
31     public int getBytesWritten() {
32         return ((CountedOutputStream)out).getBytesWritten();
33     }
34 }
35
Popular Tags