Mercurial > projects > dwt-mac
comparison dwt/dwthelper/OutputStream.d @ 0:380af2bdd8e5
Upload of whole dwt tree
author | Jacob Carlborg <doob@me.com> <jacob.carlborg@gmail.com> |
---|---|
date | Sat, 09 Aug 2008 17:00:02 +0200 |
parents | |
children | db5a898b2119 |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:380af2bdd8e5 |
---|---|
1 /** | |
2 * Authors: Frank Benoit <keinfarbton@googlemail.com> | |
3 */ | |
4 module dwt.dwthelper.OutputStream; | |
5 | |
6 import dwt.dwthelper.utils; | |
7 static import tango.io.model.IConduit; | |
8 | |
9 public abstract class OutputStream { | |
10 | |
11 private tango.io.model.IConduit.OutputStream ostr; | |
12 | |
13 public this(){ | |
14 } | |
15 | |
16 protected this( tango.io.model.IConduit.OutputStream aOutStream) { | |
17 this.ostr = aOutStream; | |
18 } | |
19 | |
20 protected this(OutputStream rhs) { | |
21 ostr = rhs.ostr; | |
22 } | |
23 | |
24 public abstract void write( int b ); | |
25 | |
26 public void write( byte[] b ){ | |
27 ostr.write(b); | |
28 } | |
29 | |
30 public void write(char[] c) { | |
31 ostr.write(c); | |
32 } | |
33 | |
34 public void write( byte[] b, int off, int len ){ | |
35 implMissing( __FILE__, __LINE__ ); | |
36 } | |
37 | |
38 public void flush(){ | |
39 ostr.flush(); | |
40 } | |
41 | |
42 public void close(){ | |
43 ostr.flush(); | |
44 implMissing( __FILE__, __LINE__ ); | |
45 } | |
46 | |
47 | |
48 } | |
49 | |
50 |