com.ibm.jarm.api.exception

Class RMRuntimeException

  • java.lang.Object
    • java.lang.Throwable
      • java.lang.Exception
        • java.lang.RuntimeException
          • com.ibm.jarm.api.exception.RMRuntimeException
  • All Implemented Interfaces:
    java.io.Serializable
    Direct Known Subclasses:
    IERWorkflowException


    public class RMRuntimeException
    extends java.lang.RuntimeException
    Primary exception class for the JARM API.

    The Locale used in generation of the RMRuntimeException's message string is based on the value of the current thread's RMUserContext. The JarmLogger locale determines how the exception message is localized for purposes of error logging.

    This differentiation ensures that all logging entry messages are based on the same locale while the message attached to a RMRuntimeException instance is based upon the locale of the current user, since the message is displayed to that user.

    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field and Description
      static java.lang.String IBM_PREFIX
      The IBM Message Standard three-character prefix assigned to IBM Enterprise Records products.
      static java.lang.String MESSAGE_ID_PREFIX
      The prefix string for all logging message ID key values.
      static char MESSAGE_ID_SUFFIX
      The Severity suffix character used for all RMRuntimeException Message IDs.
      static java.lang.String SWG_ID
      The IBM SWG Component ID assigned to the IBM Enterprise Records API.
      static java.lang.String W3C_DATE_FORMAT
      A date format pattern string for the w3c date format standard.
      static java.lang.String W3C_DATE_FORMAT_WITH_ZONE
      A date format pattern string for the w3c date format standard that includes time zone information.
    • Field Detail

      • IBM_PREFIX

        public static final java.lang.String IBM_PREFIX
        The IBM Message Standard three-character prefix assigned to IBM Enterprise Records products.
        See Also:
        Constant Field Values
      • SWG_ID

        public static final java.lang.String SWG_ID
        The IBM SWG Component ID assigned to the IBM Enterprise Records API.
        See Also:
        Constant Field Values
      • MESSAGE_ID_PREFIX

        public static final java.lang.String MESSAGE_ID_PREFIX
        The prefix string for all logging message ID key values. The key values are used to retrieve the appropriate localized message format string from the ResourceBundle associated with this BaseLogger instance.

        Each message ID key value consists of this prefix string plus a 4-digit numeric suffix.

        See Also:
        Constant Field Values
      • MESSAGE_ID_SUFFIX

        public static final char MESSAGE_ID_SUFFIX
        The Severity suffix character used for all RMRuntimeException Message IDs.
      • W3C_DATE_FORMAT

        public static final java.lang.String W3C_DATE_FORMAT
        A date format pattern string for the w3c date format standard.
        See Also:
        Constant Field Values
      • W3C_DATE_FORMAT_WITH_ZONE

        public static final java.lang.String W3C_DATE_FORMAT_WITH_ZONE
        A date format pattern string for the w3c date format standard that includes time zone information.
        See Also:
        Constant Field Values
    • Method Detail

      • createRMRuntimeException

        public static RMRuntimeException createRMRuntimeException(RMErrorCode code,
                                                  java.lang.Object... params)
        Creates a new RMRuntimeException instance.
        Parameters:
        code - the RMErrorCode value that defines the cause of this exception. This entry cannot be null.
        params - optional exception message formatting parameters.
        Returns:
        A new RMRuntimeException instance.
      • createRMRuntimeException

        public static RMRuntimeException createRMRuntimeException(RMErrorCode code,
                                                  RMErrorStack errorStack,
                                                  java.lang.Object... params)
        Creates a new RMRuntimeException instance.
        Parameters:
        code - the RMErrorCode value that defines the cause of this exception. This entry cannot be null.
        errorStack - a RMErrorStack containing repository-specific error information. This entry can be null.
        params - optional exception message formatting parameters.
        Returns:
        A new RMRuntimeException instance.
      • createRMRuntimeException

        public static RMRuntimeException createRMRuntimeException(java.lang.Throwable cause,
                                                  RMErrorCode code,
                                                  java.lang.Object... params)
        Creates a new RMRuntimeException instance.
        Parameters:
        cause - the underlying cause for this exception.
        code - the RMErrorCode value that defines the cause of this exception. This entry cannot be null.
        params - optional exception message formatting parameters.
        Returns:
        A new RMRuntimeException instance.
      • createRMRuntimeException

        public static RMRuntimeException createRMRuntimeException(java.lang.Throwable cause,
                                                  RMErrorCode code,
                                                  RMErrorStack errorStack,
                                                  java.lang.Object... params)
        Creates a new RMRuntimeException instance.
        Parameters:
        cause - the underlying cause for this exception.
        code - the RMErrorCode value that defines the cause of this exception. This entry cannot be null.
        errorStack - a RMErrorStack containing repository-specific error information. This entry can be null.
        params - optional exception message formatting parameters.
        Returns:
        A new RMRuntimeException instance.
      • getErrorStack

        public RMErrorStack getErrorStack()
        Returns a repository-specific RMErrorStack instance, if any, that provides additional repository-related information concerning the exception.
        Returns:
        A RMErrorStack instance. This value can be null.
      • getMessageInfo

        public MessageInfo getMessageInfo()
        Returns a MessageInfo instance that provides various localized information strings about this RMRuntimeException instance such as a detailed explanation and suggested user action to resolve the exception issue.
        Returns:
        A MessageInfo instance.
      • formatDate

        public static java.lang.String formatDate(java.util.Date dateValue)
        Helper method to format a java.util.Date value as a String for use within an exception message.
        Parameters:
        dateValue - the java.util.Date value to format. This entry can be null.
        Returns:
        A String value.

© Copyright IBM Corp. 2010, 2013. All Rights Reserved.