code: public String getMessageProcessType(BaseMessage externalMessage)
      {
          if (externalMessage.getMessageHeader() != null)
              if (externalMessage.getMessageHeader().get(TrxMessageHeader.MESSAGE_PROCESS_TYPE) != null)
                  return (String)externalMessage.getMessageHeader().get(TrxMessageHeader.MESSAGE_PROCESS_TYPE);
          return MessageTypeModel.MESSAGE_IN;   // Override this to check for sure.
      }
docs: Is this message a reply (or a request).
  @param externalMessage The incomming message.
  @return MessageType.MESSAGE_IN or MessageType.REPLY_IN If this is a reply.