01: package vicazh.hyperpool.stream;
02:
03: import java.io.*;
04:
05: class DialClientStream extends Stream {
06:
07: DialClientStream(Connection connection, OutputStream outputstream) {
08: super (connection, outputstream);
09: }
10:
11: private boolean f;
12:
13: public void write(int i) throws IOException {
14: if (((DialConnection) connection).b || f)
15: super .write(i);
16: else {
17: ((DialConnection) connection).astream.write(i);
18: try {
19: super .write(i);
20: } catch (Exception e) {
21: ((DialConnection) connection).dial();
22: f = true;
23: }
24: }
25: }
26: }
|