1 package net.sourceforge.phpeclipse.phpunit;
3 import java.io.BufferedReader;
4 import java.io.IOException;
5 import java.io.InputStreamReader;
6 import java.net.Socket;
8 public class ReportListener extends Thread {
13 public ReportListener(Socket serviceSocket, PHPUnitView view) {
15 this.serviceSocket = serviceSocket;
21 InputStreamReader reader;
24 reader = new InputStreamReader(serviceSocket.getInputStream());
26 BufferedReader in = new BufferedReader(reader);
29 // keep listening until the
30 while ( (report = in.readLine()) != null &&
31 (report != "end_all_tests") ) {
33 //System.out.println("received something...");
34 view.handleReport(report);
35 //System.out.println(report);
38 //reportArea.append("Finished!");
39 System.out.println("Finished");
40 serviceSocket.close();
42 } catch (IOException e) {
43 // TODO Auto-generated catch block