home *** CD-ROM | disk | FTP | other *** search
- import java.io.DataInputStream;
- import java.io.EOFException;
- import java.io.IOException;
-
- class PrintThread extends Thread {
- Monolog output;
- DataInputStream dis;
-
- PrintThread(String var1, DataInputStream var2, Monolog var3) {
- super(var1);
- this.dis = var2;
- this.output = var3;
- }
-
- public void run() {
- try {
- while(true) {
- String var1 = this.dis.readLine();
- if (var1 == null) {
- return;
- }
-
- this.output(var1);
- }
- } catch (EOFException var2) {
- } catch (IOException var3) {
- this.output(BrowserOptions.messages.getString("IOException"));
- }
- }
-
- private void output(String var1) {
- if (this.output == null) {
- System.out.println(var1);
- } else {
- this.output.output(var1 + "\n");
- }
- }
- }
-