public void Push(OpaqueMessage msg) { if (queue == null) { throw new ExceptionMessageQueueInvalid(); } queue.Send(msg); }
public object Read(Message message) { var omsg = new OpaqueMessage { Label = LabelReformat(ReadLabelReformatExpression, message), OpaqueBodyType = message.BodyType, Length = Convert.ToInt32(message.BodyStream.Length), Id = -1, AppSpecific = message.AppSpecific }; omsg.OpaqueBody = new byte[omsg.Length]; message.BodyStream.Read(omsg.OpaqueBody, 0, omsg.Length); return(omsg); }