Class XMLSecurityRuntimeException

  • All Implemented Interfaces:
    Serializable

    public class XMLSecurityRuntimeException
    extends RuntimeException
    The mother of all runtime Exceptions in this bundle. It allows exceptions to have their messages translated to the different locales. The xmlsecurity_en.properties file contains this line:
     xml.WrongElement = Can't create a {0} from a {1} element
     
    Usage 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);
     }
     
    See Also:
    Serialized Form
    • Field Detail

      • msgID

        protected String msgID
        Field msgID
    • Constructor Detail

      • XMLSecurityRuntimeException

        public XMLSecurityRuntimeException()
        Constructor XMLSecurityRuntimeException
      • XMLSecurityRuntimeException

        public XMLSecurityRuntimeException​(String msgID)
        Constructor XMLSecurityRuntimeException
        Parameters:
        msgID -
      • XMLSecurityRuntimeException

        public XMLSecurityRuntimeException​(String msgID,
                                           Object[] exArgs)
        Constructor XMLSecurityRuntimeException
        Parameters:
        msgID -
        exArgs -
      • XMLSecurityRuntimeException

        public XMLSecurityRuntimeException​(Exception originalException)
        Constructor XMLSecurityRuntimeException
        Parameters:
        originalException -
      • XMLSecurityRuntimeException

        public XMLSecurityRuntimeException​(String msgID,
                                           Exception originalException)
        Constructor XMLSecurityRuntimeException
        Parameters:
        msgID -
        originalException -
      • XMLSecurityRuntimeException

        public XMLSecurityRuntimeException​(String msgID,
                                           Object[] exArgs,
                                           Exception originalException)
        Constructor XMLSecurityRuntimeException
        Parameters:
        msgID -
        exArgs -
        originalException -
    • Method Detail

      • getMsgID

        public String getMsgID()
        Method getMsgID
        Returns:
        the messageId
      • getOriginalException

        public Exception getOriginalException()
        Method getOriginalException
        Returns:
        the original exception