Package org.alfresco.error
Class AlfrescoRuntimeException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- org.alfresco.error.AlfrescoRuntimeException
-
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
CannedQueryException
,ConnectionPoolException
,ScriptException
@AlfrescoPublicApi public class AlfrescoRuntimeException extends RuntimeException
I18n'ed runtime exception thrown by Alfresco code.- Author:
- gavinc
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description AlfrescoRuntimeException(String msgId)
ConstructorAlfrescoRuntimeException(String msgId, Object[] msgParams)
ConstructorAlfrescoRuntimeException(String msgId, Object[] msgParams, Throwable cause)
ConstructorAlfrescoRuntimeException(String msgId, Throwable cause)
Constructor
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static AlfrescoRuntimeException
create(String msgId, Object... objects)
Helper factory method making use of variable argument numbersstatic AlfrescoRuntimeException
create(Throwable cause, String msgId, Object... objects)
Helper factory method making use of variable argument numbersString
getMsgId()
Object[]
getMsgParams()
String
getNumericalId()
Throwable
getRootCause()
Get the root cause.static RuntimeException
makeRuntimeException(Throwable e, String msgId, Object... objects)
Utility to convert a general Throwable to a RuntimeException.-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
AlfrescoRuntimeException
public AlfrescoRuntimeException(String msgId)
Constructor- Parameters:
msgId
- the message id
-
AlfrescoRuntimeException
public AlfrescoRuntimeException(String msgId, Object[] msgParams)
Constructor- Parameters:
msgId
- the message idmsgParams
- the message parameters
-
AlfrescoRuntimeException
public AlfrescoRuntimeException(String msgId, Throwable cause)
Constructor- Parameters:
msgId
- the message idcause
- the exception cause
-
-
Method Detail
-
create
public static AlfrescoRuntimeException create(String msgId, Object... objects)
Helper factory method making use of variable argument numbers
-
create
public static AlfrescoRuntimeException create(Throwable cause, String msgId, Object... objects)
Helper factory method making use of variable argument numbers
-
makeRuntimeException
public static RuntimeException makeRuntimeException(Throwable e, String msgId, Object... objects)
Utility to convert a general Throwable to a RuntimeException. No conversion is done if the throwable is already a RuntimeException.- See Also:
create(Throwable, String, Object...)
-
getMsgId
public String getMsgId()
- Returns:
- the msgId
-
getMsgParams
public Object[] getMsgParams()
- Returns:
- the msgParams
-
getNumericalId
public String getNumericalId()
- Returns:
- the numericalId
-
getRootCause
public Throwable getRootCause()
Get the root cause.
-
-