Class XTCEViewerUncaughtExceptionHandler

  • All Implemented Interfaces:
    Thread.UncaughtExceptionHandler

    public final class XTCEViewerUncaughtExceptionHandler
    extends Object
    implements Thread.UncaughtExceptionHandler
    This class implements an exception handler of last resort to prevent the graphical user interface from crashing or dropping unintelligible text to STDOUT.
    Author:
    David Overeem
    • Method Detail

      • uncaughtException

        public void uncaughtException​(Thread id,
                                      Throwable ex)
        Method that is called by Java when no exception handler is defined. This methods changes the behavior such that the uncaught exception will be caught and the localized message displayed to a JOptionPane dialog box with ERROR_MESSAGE specialization. The message can be acknowledged and processing will continue.
        Specified by:
        uncaughtException in interface Thread.UncaughtExceptionHandler
        Parameters:
        id - Thread that generated the exception, not otherwise used here.
        ex - Throwable base class for all Java exceptions, which is used to extract any kind of useful error message that might be there.