docs: private short getExceptionId(Throwable exception)
     {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.entry(tc, "getExceptionId");
  
        short exceptionId = CommsConstants.EXCEPTION_INTERNAL_ERROR;
  
        // ******** Do the SIIncorrectExcecption branch and all its subclasses
        if (exception instanceof SIInvalidDestinationPrefixException)
           exceptionId = CommsConstants.SI_INVALID_DESTINATION_PREFIX_EXCEPTION;
  
        else if (exception instanceof SIDiscriminatorSyntaxException)
           exceptionId = CommsConstants.SI_DISCRIMINATOR_SYNTAX_EXCEPTION;
  
        else if (exception instanceof SISelectorSyntaxException)
           exceptionId = CommsConstants.SI_SELECTOR_SYNTAX_EXCEPTION;
  
        else if (exception instanceof SIInsufficientDataForFactoryTypeException)
           exceptionId = CommsConstants.SI_INSUFFICIENT_DATA_FOR_FACT_EXCEPTION;
  
        else if (exception instanceof SIIncorrectCallException)
           exceptionId = CommsConstants.SI_INCORRECT_CALL_EXCEPTION;
  
        // ******** Now the SIAuthenticationException branch
        else if (exception instanceof SIAuthenticationException)
           exceptionId = CommsConstants.SI_AUTHENTICATION_EXCEPTION;
  
        // ******** Now the SINotPossibleInCurrentConfigurationException branch
        else if (exception instanceof SINotAuthorizedException)
           exceptionId = CommsConstants.SI_NOT_AUTHORISED_EXCEPTION;
  
        else if (exception instanceof SINotPossibleInCurrentConfigurationException)
           exceptionId = CommsConstants.SI_NOT_POSSIBLE_IN_CUR_CONFIG_EXCEPTION;
  
        // ******** Now the SINotPossibleInCurrentStateException branch
        else if (exception instanceof SISessionDroppedException)
           exceptionId = CommsConstants.SI_SESSION_DROPPED_EXCEPTION;
  
        else if (exception instanceof SISessionUnavailableException)
           exceptionId = CommsConstants.SI_SESSION_UNAVAILABLE_EXCEPTION;
  
        else if (exception instanceof SIDurableSubscriptionAlreadyExistsException)
           exceptionId = CommsConstants.SI_DURSUB_ALREADY_EXISTS_EXCEPTION;
  
        else if (exception instanceof SIDurableSubscriptionMismatchException)
           exceptionId = CommsConstants.SI_DURSUB_MISMATCH_EXCEPTION;
  
        else if (exception instanceof SIDurableSubscriptionNotFoundException)
           exceptionId = CommsConstants.SI_DURSUB_NOT_FOUND_EXCEPTION;
  
        else if (exception instanceof SIConnectionDroppedException)
           exceptionId = CommsConstants.SI_CONNECTION_DROPPED_EXCEPTION;
  
        else if (exception instanceof SIConnectionUnavailableException)
           exceptionId = CommsConstants.SI_CONNECTION_UNAVAILABLE_EXCEPTION;
  
        else if (exception instanceof SIDataGraphFormatMismatchException)
           exceptionId = CommsConstants.SI_DATAGRAPH_FORMAT_MISMATCH_EXCEPTION;
  
        else if (exception instanceof SIDataGraphSchemaNotFoundException)
           exceptionId = CommsConstants.SI_DATAGRAPH_SCHEMA_NOT_FOUND_EXCEPTION;
  
        else if (exception instanceof SIDestinationLockedException)
           exceptionId = CommsConstants.SI_DESTINATION_LOCKED_EXCEPTION;
  
        else if (exception instanceof SITemporaryDestinationNotFoundException)
           exceptionId = CommsConstants.SI_TEMPORARY_DEST_NOT_FOUND_EXCEPTION;
  
        // ******** Now the SIMessageException branch
        else if (exception instanceof SIMessageException)
           exceptionId = CommsConstants.SI_MESSAGE_EXCEPTION;
  
        // ******** Now the SIResourceException branch
        else if (exception instanceof SILimitExceededException)
           exceptionId = CommsConstants.SI_LIMIT_EXCEEDED_EXCEPTION;
  
        else if (exception instanceof SIConnectionLostException)
           exceptionId = CommsConstants.SI_CONNECTION_LOST_EXCEPTION;
  
        else if (exception instanceof SIRollbackException)
           exceptionId = CommsConstants.SI_ROLLBACK_EXCEPTION;
  
        else if (exception instanceof SIResourceException)
           exceptionId = CommsConstants.SI_RESOURCE_EXCEPTION;
  
        // ******** Now the SINotSupportedException branch
        else if (exception instanceof SIMessageDomainNotSupportedException)
           exceptionId = CommsConstants.SI_MSG_DOMAIN_NOT_SUPPORTED_EXCEPTION;
  
        else if (exception instanceof SINotSupportedException)
           exceptionId = CommsConstants.SI_NOT_SUPPORTED_EXCEPTION;
  
        // ******** Now the SIDataGraphException
        else if (exception instanceof SIDataGraphException)
           exceptionId = CommsConstants.SI_DATAGRAPH_EXCEPTION;
  
        // ******** Now the SICommandInvocationFailedException
        else if (exception instanceof SICommandInvocationFailedException)
           exceptionId = CommsConstants.SI_COMMAND_INVOCATION_FAILED_EXCEPTION;
  
        // ******** Now the SIMessageNotLockedException
        else if (exception instanceof SIMessageNotLockedException)
           exceptionId = CommsConstants.SI_MESSAGE_NOT_LOCKED_EXCEPTION;
  
        // ******** And the runtime one
        else if (exception instanceof SIErrorException)
           exceptionId = CommsConstants.SI_ERROR_EXCEPTION;
  
        // ******** Now the top level SIException
        else if (exception instanceof SIException)
           exceptionId = CommsConstants.SI_EXCEPTION;
  
        // Don't forget XA
        else if (exception instanceof XAException)
           exceptionId = CommsConstants.EXCEPTION_XAEXCEPTION;
  
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.exit(tc, "getExceptionId", ""+exceptionId);
        return exceptionId;
     }