private void reportException(Exception e){
  e.printStackTrace(System.out);
  JOptionPane.showMessageDialog(this,StringUtil.getStackTrace(e),"Exception",JOptionPane.ERROR_MESSAGE);
}

private void reportException ( Exception e ) { e . printStackTrace ( System . out ) ; JOptionPane . showMessageDialog ( this , StringUtil . getStackTrace ( e ) , "Exception" , JOptionPane . ERROR_MESSAGE ) ; }
reports the exception to the user .
