finally { if (monitor[0] != null) synchronized (monitor[0]) { monitor[0].notify(); }
catch (Exception e) { e.printStackTrace();
      public void run() {        try {          int index = tblSongs.getSelectionIndex();          Track track;          if (index < 0)            answer[0] = getPlayingTrack();          else            answer[0] = getTrackByTableItem(tblSongs.getItems()[index]);        }        finally {          if (monitor[0] != null)            synchronized (monitor[0]) {              monitor[0].notify();            }        }      }