I am trying to do following in gui class for notifying registred observers.
public class GUI extends javax.swing.JFrame implements Observer {
public notImportantMethod() {
 t = new Thread() {
            @Override
            public void run() {
                for (int i = 1; i <= 10; i++) {
                       myObject.registerObserver(this);   
                 }
            }
        };
        t.start();
      }
}
It gives me error: incompatible types: cannot be converted to Observer How can I use this? I know inside of run there is another context but how could I access it?
 
     
     
     
    