code: public void registerMessage(MessageItem msg, TransactionCommon tran) throws SIIncorrectCallException
    {
      if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
        SibTr.entry(tc, "registerMessage", new Object[] { msg, tran });
  
      if (tran != null && !tran.isAlive())
      {
        SIMPIncorrectCallException e = new SIMPIncorrectCallException(
          nls_cwsik.getFormattedMessage(
             "DELIVERY_ERROR_SIRC_16",  // TRANSACTION_SEND_USAGE_ERROR_CWSIP0093
             new Object[] { _destination },
             null) );
  
        e.setExceptionReason(SIRCConstants.SIRC0016_TRANSACTION_SEND_USAGE_ERROR);
        e.setExceptionInserts(new String[] { _destination.getName() });
  
        if (TraceComponent.isAnyTracingEnabled() && tc.isEventEnabled())
          SibTr.exception(tc, e);
  
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
          SibTr.exit(tc, "registerMessage", e);
  
        throw e;
      }
  
      registerForEvents(msg);
  
      /* Register the message with the pre-prepare callback on the transaction.
       * When called back, the choice of OutputHandler for the message is made
       * and the message is put to the itemstream of the chosen OutputHandler.
       */
      tran.registerCallback(msg);
  
      if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
        SibTr.exit(tc, "registerMessage");
    }
docs: Method registerMessage.
  @param msg
  @param tran
  <p>Register the message with the pre-prepare callback on the transaction.
  When called back, the choice of OutputHandler for the message is made
  and the message is put to the itemstream of the chosen OutputHandler.
  </p>