com.compomics.util.general
Class ExceptionHandler

java.lang.Object
  extended by com.compomics.util.general.ExceptionHandler

public class ExceptionHandler
extends Object

Handles exception for a given application.

Author:
Marc Vaudel

Constructor Summary
ExceptionHandler()
          Constructor without GUI.
ExceptionHandler(JFrame parent)
          Constructor.
 
Method Summary
 void catchException(Exception e)
          Method called whenever an exception is caught.
static String getExceptionType(Exception e)
          Returns the exception type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExceptionHandler

public ExceptionHandler(JFrame parent)
Constructor.

Parameters:
parent - the parent frame used to display feedback

ExceptionHandler

public ExceptionHandler()
Constructor without GUI.

Method Detail

catchException

public void catchException(Exception e)
Method called whenever an exception is caught.

Parameters:
e - the exception caught

getExceptionType

public static String getExceptionType(Exception e)
Returns the exception type.

Parameters:
e - the exception to get the type fro
Returns:
the exception type as a string


Copyright © 2013. All Rights Reserved.