org.olat.core.logging
Class OLATRuntimeException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.lang.RuntimeException
              extended by org.olat.core.logging.OLATRuntimeException
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
AssertException, DBRuntimeException, KnownIssueException, OLATSecurityException, StartupException

public class OLATRuntimeException
extends java.lang.RuntimeException

Description:
Thrown if an unrecoverable error occurs. These Exceptions get caught by the Servlet. The user will get an orange screen and a log message is recorded.

Author:
Felix Jost
See Also:
Serialized Form

Constructor Summary
OLATRuntimeException(java.lang.Class throwingClazz, java.lang.String usrMsgKey, java.lang.String[] usrMsgArgs, java.lang.String usrMsgPackage, java.lang.String logMsg, java.lang.Throwable cause)
           
OLATRuntimeException(java.lang.Class throwingClazz, java.lang.String logMsg, java.lang.Throwable cause)
           
OLATRuntimeException(java.lang.String usrMsgKey, java.lang.String[] usrMsgArgs, java.lang.String usrMsgPackage, java.lang.String logMsg, java.lang.Throwable cause)
           
OLATRuntimeException(java.lang.String logMsg, java.lang.Throwable cause)
           
 
Method Summary
 java.lang.String getLogMsg()
           
 java.lang.Class getThrowingClazz()
           
 java.lang.String[] getUsrMsgArgs()
           
 java.lang.String getUsrMsgKey()
           
 java.lang.String getUsrMsgPackage()
           
static java.lang.StringBuilder throwableToHtml(java.lang.Throwable th)
          Format throwable as HTML fragment.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

OLATRuntimeException

public OLATRuntimeException(java.lang.Class throwingClazz,
                            java.lang.String usrMsgKey,
                            java.lang.String[] usrMsgArgs,
                            java.lang.String usrMsgPackage,
                            java.lang.String logMsg,
                            java.lang.Throwable cause)
Parameters:
throwing - class
usrMsgKey -
usrMsgArgs -
usrMsgPackage -
logMsg -
cause -

OLATRuntimeException

public OLATRuntimeException(java.lang.String usrMsgKey,
                            java.lang.String[] usrMsgArgs,
                            java.lang.String usrMsgPackage,
                            java.lang.String logMsg,
                            java.lang.Throwable cause)
Parameters:
usrMsgKey -
usrMsgArgs -
usrMsgPackage -
logMsg -
cause -

OLATRuntimeException

public OLATRuntimeException(java.lang.Class throwingClazz,
                            java.lang.String logMsg,
                            java.lang.Throwable cause)
Parameters:
category -
logMsg -
cause -

OLATRuntimeException

public OLATRuntimeException(java.lang.String logMsg,
                            java.lang.Throwable cause)
Parameters:
logMsg -
cause -
Method Detail

throwableToHtml

public static java.lang.StringBuilder throwableToHtml(java.lang.Throwable th)
Format throwable as HTML fragment.

Parameters:
th -
Returns:
HTML fragment.

getLogMsg

public java.lang.String getLogMsg()
Returns:
the log message

getThrowingClazz

public java.lang.Class getThrowingClazz()

getUsrMsgKey

public java.lang.String getUsrMsgKey()
Returns:
String key of user message in the given package

getUsrMsgPackage

public java.lang.String getUsrMsgPackage()
Returns:
String package name where usr msg key is found

getUsrMsgArgs

public java.lang.String[] getUsrMsgArgs()
Returns:
String[] The translator arguments or null if none available