swingx
Version 2005-08-19

org.jdesktop.swingx
Class IncidentInfo

java.lang.Object
  extended by org.jdesktop.swingx.IncidentInfo

public class IncidentInfo
extends Object


Constructor Summary
IncidentInfo(String header, String basicErrorMessage, String detailedErrorMessage)
          Constructor that creates IncidentInfo with all the provided descriptions
IncidentInfo(String header, String basicErrorMessage, String detailedErrorMessage, Throwable errorException)
          Main constructor that adds all the information to IncidentInfo
IncidentInfo(String header, Throwable errorException)
          Constructor that creates IncidentInfo retreiving all the information from the provided Throwable
 
Method Summary
 String getBasicErrorMessage()
          Get the basic error description
 String getDetailedErrorMessage()
          Get the detailed error description
 Throwable getErrorException()
          Get an exception that contains some additional information about the error if provided.
 Level getErrorLevel()
          Returns the severity of the Error.
 String getHeader()
          Get the current header string
 void setBasicErrorMessage(String basicErrorMessage)
          Set the current basic error description
 void setDetailedErrorMessage(String detailedErrorMessage)
          Set the detailed description for this error
 void setErrorException(Throwable errorException)
          Set the exception that may contain additional information about the error.
 void setErrorLevel(Level errorLevel)
          Sets the error level for this IncidentInfo
 void setHeader(String header)
          Set the current header string
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IncidentInfo

public IncidentInfo(String header,
                    String basicErrorMessage,
                    String detailedErrorMessage,
                    Throwable errorException)
Main constructor that adds all the information to IncidentInfo

Parameters:
header - Header that will be used as the quick reference for the incident (e.g. title for a dialog or subject for the incident message)
basicErrorMessage - Short description of the given problem
detailedErrorMessage - Full description of the problem
errorException - Throwable that can be used as a source for additional information such as call stack, thread name, etc.

IncidentInfo

public IncidentInfo(String header,
                    String basicErrorMessage,
                    String detailedErrorMessage)
Constructor that creates IncidentInfo with all the provided descriptions

Parameters:
header - Header that will be used as the quick reference for the incident (e.g. title for a dialog or subject for the incident message)
basicErrorMessage - Short description of the given problem
detailedErrorMessage - Full description og the problem

IncidentInfo

public IncidentInfo(String header,
                    Throwable errorException)
Constructor that creates IncidentInfo retreiving all the information from the provided Throwable

Parameters:
header - Header that will be used as the quick reference for the incident (e.g. title for a dialog or subject for the incident message)
errorException - Throwable that can be used as a main source of information about the incident
Method Detail

getHeader

public String getHeader()
Get the current header string

Returns:
header string

setHeader

public void setHeader(String header)
Set the current header string

Parameters:
header -

getBasicErrorMessage

public String getBasicErrorMessage()
Get the basic error description

Returns:
basic error description

setBasicErrorMessage

public void setBasicErrorMessage(String basicErrorMessage)
Set the current basic error description

Parameters:
basicErrorMessage - new basic error description

getDetailedErrorMessage

public String getDetailedErrorMessage()
Get the detailed error description

Returns:
detailed description

setDetailedErrorMessage

public void setDetailedErrorMessage(String detailedErrorMessage)
Set the detailed description for this error

Parameters:
detailedErrorMessage - new detailed description

getErrorException

public Throwable getErrorException()
Get an exception that contains some additional information about the error if provided.

Returns:
exception or null if no exception provided

setErrorException

public void setErrorException(Throwable errorException)
Set the exception that may contain additional information about the error.

Parameters:
errorException - new Throwable or null if there is no Throwable related to this error

getErrorLevel

public Level getErrorLevel()
Returns the severity of the Error. This defaults to Level.SEVERE, but may be specified via setErrorLevel

Returns:
the Level. This will never be null

setErrorLevel

public void setErrorLevel(Level errorLevel)
Sets the error level for this IncidentInfo

Parameters:
errorLevel - any Level (Level.SEVERE, Level.WARNING, etc). If null, then the level will be set to SEVERE.

swingx
Version 2005-08-19