Class XMLSecurityRuntimeException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- org.apache.xml.security.exceptions.XMLSecurityRuntimeException
-
- All Implemented Interfaces:
java.io.Serializable
public class XMLSecurityRuntimeException extends java.lang.RuntimeExceptionThe mother of all runtime Exceptions in this bundle. It allows exceptions to have their messages translated to the different locales. Thexmlsecurity_en.propertiesfile contains this line:xml.WrongElement = Can't create a {0} from a {1} elementUsage in the Java source is:{ Object exArgs[] = { Constants._TAG_TRANSFORMS, "BadElement" }; throw new XMLSecurityException("xml.WrongElement", exArgs); }Additionally, if another Exception has been caught, we can supply it, too>try { ... } catch (Exception oldEx) { Object exArgs[] = { Constants._TAG_TRANSFORMS, "BadElement" }; throw new XMLSecurityException("xml.WrongElement", exArgs, oldEx); }- Author:
- Christian Geuer-Pollmann
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.StringmsgIDField msgIDprotected java.lang.ExceptionoriginalExceptionField originalException
-
Constructor Summary
Constructors Constructor Description XMLSecurityRuntimeException()Constructor XMLSecurityRuntimeExceptionXMLSecurityRuntimeException(java.lang.Exception _originalException)Constructor XMLSecurityRuntimeExceptionXMLSecurityRuntimeException(java.lang.String _msgID)Constructor XMLSecurityRuntimeExceptionXMLSecurityRuntimeException(java.lang.String _msgID, java.lang.Exception _originalException)Constructor XMLSecurityRuntimeExceptionXMLSecurityRuntimeException(java.lang.String _msgID, java.lang.Object[] exArgs)Constructor XMLSecurityRuntimeExceptionXMLSecurityRuntimeException(java.lang.String _msgID, java.lang.Object[] exArgs, java.lang.Exception _originalException)Constructor XMLSecurityRuntimeException
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetMsgID()Method getMsgIDjava.lang.ExceptiongetOriginalException()Method getOriginalExceptionvoidprintStackTrace()Method printStackTracevoidprintStackTrace(java.io.PrintStream printstream)Method printStackTracevoidprintStackTrace(java.io.PrintWriter printwriter)Method printStackTracejava.lang.StringtoString()
-
-
-
Constructor Detail
-
XMLSecurityRuntimeException
public XMLSecurityRuntimeException()
Constructor XMLSecurityRuntimeException
-
XMLSecurityRuntimeException
public XMLSecurityRuntimeException(java.lang.String _msgID)
Constructor XMLSecurityRuntimeException- Parameters:
_msgID-
-
XMLSecurityRuntimeException
public XMLSecurityRuntimeException(java.lang.String _msgID, java.lang.Object[] exArgs)Constructor XMLSecurityRuntimeException- Parameters:
_msgID-exArgs-
-
XMLSecurityRuntimeException
public XMLSecurityRuntimeException(java.lang.Exception _originalException)
Constructor XMLSecurityRuntimeException- Parameters:
_originalException-
-
XMLSecurityRuntimeException
public XMLSecurityRuntimeException(java.lang.String _msgID, java.lang.Exception _originalException)Constructor XMLSecurityRuntimeException- Parameters:
_msgID-_originalException-
-
XMLSecurityRuntimeException
public XMLSecurityRuntimeException(java.lang.String _msgID, java.lang.Object[] exArgs, java.lang.Exception _originalException)Constructor XMLSecurityRuntimeException- Parameters:
_msgID-exArgs-_originalException-
-
-
Method Detail
-
getMsgID
public java.lang.String getMsgID()
Method getMsgID- Returns:
- the messageId
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Throwable
-
printStackTrace
public void printStackTrace()
Method printStackTrace- Overrides:
printStackTracein classjava.lang.Throwable
-
printStackTrace
public void printStackTrace(java.io.PrintWriter printwriter)
Method printStackTrace- Overrides:
printStackTracein classjava.lang.Throwable- Parameters:
printwriter-
-
printStackTrace
public void printStackTrace(java.io.PrintStream printstream)
Method printStackTrace- Overrides:
printStackTracein classjava.lang.Throwable- Parameters:
printstream-
-
getOriginalException
public java.lang.Exception getOriginalException()
Method getOriginalException- Returns:
- the original exception
-
-