Hi I create two thread first thread to call application and second thread for read file that result from calling aplication on the first thread. Call application work fine but read the file doesnt work. can you help me plz? here is my code
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package reciverwindow;
import java.util.logging.Level;
import java.util.logging.Logger;
/**
*
*
*/
public class NewClass1 implements Runnable {
public static void main(String[] args) {
CallMatlab c = new CallMatlab();
CUI m = new CUI();
Thread t1 = new Thread(c);
t1.start();
Thread t2 = new Thread(m);
t2.start();
/* try {
t2.sleep(3);
} catch (InterruptedException ex) {
Logger.getLogger(NewClass1.class.getName()).log(Level.SEVERE, null, ex);
}
}*/
synchronized (t2) {
try {
t2.wait(3);
t2.notifyAll();
} catch (InterruptedException ex) {
Logger.getLogger(NewClass1.class.getName()).log(Level.SEVERE, null, ex);
}
}
}
public void run() {
throw new UnsupportedOperationException("Not supported yet.");
}
}