processMonitor.stopMonitoring();
                public void windowClosed(WindowEvent e) {                    if(currentProcess!=null) {                        processInput.close();                        currentProcess.destroy();                        processMonitor.stopMonitoring();                    }                }