コード例 #1
0
 /// <summary>
 /// Creates the content header properties from a buffer.
 /// </summary>
 /// <param name="classId">The class id.</param>
 /// <param name="propertyFlags">The property flags.</param>
 /// <param name="buffer">The buffer.</param>
 /// <returns>a populated properties structure</returns>
 /// <exception cref="AMQFrameDecodingException">if the buffer cannot be decoded</exception>
 public IContentHeaderProperties CreateContentHeaderProperties(ushort classId, ushort propertyFlags,
                                                               ByteBuffer buffer)             
 {
     IContentHeaderProperties properties;
     switch (classId)
     {
         case 60:
             properties = new BasicContentHeaderProperties();
             break;
         default:
             throw new AMQFrameDecodingException("Unsupport content header class id: " + classId);
     }
     properties.PopulatePropertiesFromBuffer(buffer, propertyFlags);
     return properties;
 }
コード例 #2
0
        /// <summary>
        /// Creates the content header properties from a buffer.
        /// </summary>
        /// <param name="classId">The class id.</param>
        /// <param name="propertyFlags">The property flags.</param>
        /// <param name="buffer">The buffer.</param>
        /// <returns>a populated properties structure</returns>
        /// <exception cref="AMQFrameDecodingException">if the buffer cannot be decoded</exception>
        public IContentHeaderProperties CreateContentHeaderProperties(ushort classId, ushort propertyFlags,
                                                                      ByteBuffer buffer)
        {
            IContentHeaderProperties properties;

            switch (classId)
            {
            case 60:
                properties = new BasicContentHeaderProperties();
                break;

            default:
                throw new AMQFrameDecodingException("Unsupport content header class id: " + classId);
            }
            properties.PopulatePropertiesFromBuffer(buffer, propertyFlags);
            return(properties);
        }
コード例 #3
0
 protected AbstractQmsMessage(BasicContentHeaderProperties contentHeader, long deliveryTag) : base(contentHeader, deliveryTag)
 {
     Init(null);
 }
コード例 #4
0
 protected AbstractQmsMessage(long deliveryTag, BasicContentHeaderProperties contentHeader, ByteBuffer data)
     : this(contentHeader, deliveryTag)
 {
     Init(data);
 }
コード例 #5
0
 internal QpidTextMessage(long deliveryTag, BasicContentHeaderProperties contentHeader, ByteBuffer data)
     :base(deliveryTag, contentHeader, data)
 {
 }
コード例 #6
0
        public static AMQFrame CreateAMQFrame(ushort channelId, ushort classId, ushort weight, BasicContentHeaderProperties properties,
                                              uint bodySize)
        {
            AMQFrame frame = new AMQFrame();

            frame.Channel   = channelId;
            frame.BodyFrame = new ContentHeaderBody(classId, weight, properties, bodySize);
            return(frame);
        }
コード例 #7
0
 public static AMQFrame CreateAMQFrame(ushort channelId, ushort classId, ushort weight, BasicContentHeaderProperties properties,
                                       uint bodySize)
 {
     AMQFrame frame = new AMQFrame();
     frame.Channel = channelId;
     frame.BodyFrame = new ContentHeaderBody(classId, weight, properties, bodySize);
     return frame;
 }