Пример #1
0
        public void SendLockReleaseResponse(System.Messaging.Message requestMessage, bool releaseLock)
        {
            MessageBody receivedMessageBody = (MessageBody)requestMessage.Body;
            LockReleaseResponseMessageBody responseMessageBody = new LockReleaseResponseMessageBody(receivedMessageBody, releaseLock);

            if (releaseLock == true)
            {
                if (this.ReleaseLock != null)
                {
                    this.ReleaseLock(receivedMessageBody.MasterAccessionNo, new EventArgs());
                }
            }

            System.Messaging.Message responseMessage = new System.Messaging.Message(responseMessageBody);
            requestMessage.ResponseQueue.Send(responseMessage);

            MessageQueueMessage responseMessageQueueMessage = new MessageQueueMessage(responseMessage, MessageDirectionEnum.Sent);

            this.m_MessageCollection.Add(responseMessageQueueMessage);
        }
Пример #2
0
        public void SendLockReleaseResponse(System.Messaging.Message requestMessage, bool releaseLock)
        {
            MessageBody receivedMessageBody = (MessageBody)requestMessage.Body;
            LockReleaseResponseMessageBody responseMessageBody = new LockReleaseResponseMessageBody(receivedMessageBody, releaseLock);

            if(releaseLock == true) if (this.ReleaseLock != null) this.ReleaseLock(receivedMessageBody.MasterAccessionNo, new EventArgs());

            System.Messaging.Message responseMessage = new System.Messaging.Message(responseMessageBody);
            requestMessage.ResponseQueue.Send(responseMessage);

            MessageQueueMessage responseMessageQueueMessage = new MessageQueueMessage(responseMessage, MessageDirectionEnum.Sent);
            this.m_MessageCollection.Add(responseMessageQueueMessage);
        }