Esempio n. 1
0
        public override TLVList getArguments()
        {
            TLVList list = new TLVList();

            if (_handle == null)
            {
                throw new MalformedMessageException("Detach header's handle can't be null");
            }

            list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(_handle));

            if (_closed != null)
            {
                list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap(_closed));
            }

            if (_error != null)
            {
                list.addElement(2, _error.getList());
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { (byte)_code }));

            list.Constructor = constructor;

            return(list);
        }
        public TLVList getList()
        {
            TLVList list = new TLVList();

            if (_condition != null)
            {
                list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(new AMQPSymbol(StringEnum.GetStringValue(_condition))));
            }

            if (_description != null)
            {
                list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap(_description));
            }

            if (_info != null)
            {
                list.addElement(2, AMQPWrapper <AMQPSymbol> .wrapMap(_info));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x1D }));

            list.Constructor = constructor;

            return(list);
        }
Esempio n. 3
0
        public TLVAmqp getValue()
        {
            TLVList list = new TLVList();

            if (_durable != null)
            {
                list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(_durable));
            }
            if (_priority != null)
            {
                list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap(_priority));
            }
            if (_milliseconds != null)
            {
                list.addElement(2, AMQPWrapper <AMQPSymbol> .wrap(_milliseconds));
            }
            if (_firstAquirer != null)
            {
                list.addElement(3, AMQPWrapper <AMQPSymbol> .wrap(_firstAquirer));
            }
            if (_deliveryCount != null)
            {
                list.addElement(4, AMQPWrapper <AMQPSymbol> .wrap(_deliveryCount));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x70 }));

            list.Constructor = constructor;

            return(list);
        }
        public override TLVList getArguments()
        {
            TLVList list = new TLVList();

            if (_mechanism == null)
            {
                throw new MalformedMessageException("SASL-Init header's mechanism can't be null");
            }

            list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(_mechanism));

            if (_initialResponse != null)
            {
                list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap(_initialResponse));
            }

            if (_hostName != null)
            {
                list.addElement(2, AMQPWrapper <AMQPSymbol> .wrap(_hostName));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x41 }));

            list.Constructor = constructor;

            return(list);
        }
Esempio n. 5
0
        public TLVList getList()
        {
            TLVList list = new TLVList();

            if (_address != null)
            {
                list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(_address));
            }

            if (_durable != null)
            {
                list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap((Int64)_durable.Value));
            }

            if (_expiryPeriod != null)
            {
                list.addElement(2, AMQPWrapper <AMQPSymbol> .wrap(new AMQPSymbol(StringEnum.GetStringValue(_expiryPeriod.Value))));
            }

            if (_timeout != null)
            {
                list.addElement(3, AMQPWrapper <AMQPSymbol> .wrap(_timeout));
            }

            if (_dynamic != null)
            {
                list.addElement(4, AMQPWrapper <AMQPSymbol> .wrap(_dynamic));
            }

            if (_dynamicNodeProperties != null)
            {
                if (_dynamic != null)
                {
                    if (_dynamic.Value)
                    {
                        list.addElement(5, AMQPWrapper <AMQPSymbol> .wrapMap(_dynamicNodeProperties));
                    }
                    else
                    {
                        throw new MalformedMessageException("Target's dynamic-node-properties can't be specified when dynamic flag is false");
                    }
                }
                else
                {
                    throw new MalformedMessageException("Target's dynamic-node-properties can't be specified when dynamic flag is not set");
                }
            }

            if (_capabilities != null)
            {
                list.addElement(6, AMQPWrapper <AMQPSymbol> .wrapArray(_capabilities));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x29 }));

            list.Constructor = constructor;

            return(list);
        }
 public void fill(TLVList list)
 {
     if (!list.isNull())
     {
         DescribedConstructor constructor = (DescribedConstructor)list.Constructor;
         _code = (LifetimePolicy)(constructor.getDescriptorCode() & 0x0ff);
     }
 }
        public TLVList getList()
        {
            TLVList list = new TLVList();
            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { (byte)_code }));

            list.Constructor = constructor;
            return(list);
        }
        public TLVAmqp getValue()
        {
            TLVAmqp val = _value != null ? AMQPWrapper <AMQPSymbol> .wrap(_value) : new TLVNull();

            DescribedConstructor constructor = new DescribedConstructor(val.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x77 }));

            val.Constructor = constructor;

            return(val);
        }
Esempio n. 9
0
        public override TLVList getArguments()
        {
            TLVList list = new TLVList();

            if (_remoteChannel != null)
            {
                list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(_remoteChannel));
            }

            if (_nextOutgoingId == null)
            {
                throw new MalformedMessageException("Begin header's next-outgoing-id can't be null");
            }
            list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap(_nextOutgoingId));

            if (_incomingWindow == null)
            {
                throw new MalformedMessageException("Begin header's incoming-window can't be null");
            }
            list.addElement(2, AMQPWrapper <AMQPSymbol> .wrap(_incomingWindow));

            if (_outgoingWindow == null)
            {
                throw new MalformedMessageException("Begin header's incoming-window can't be null");
            }
            list.addElement(3, AMQPWrapper <AMQPSymbol> .wrap(_outgoingWindow));

            if (_handleMax != null)
            {
                list.addElement(4, AMQPWrapper <AMQPSymbol> .wrap(_handleMax));
            }

            if (_offeredCapabilities != null)
            {
                list.addElement(5, AMQPWrapper <AMQPSymbol> .wrapArray(_offeredCapabilities));
            }

            if (_desiredCapabilities != null)
            {
                list.addElement(6, AMQPWrapper <AMQPSymbol> .wrapArray(_desiredCapabilities));
            }

            if (_properties != null)
            {
                list.addElement(7, AMQPWrapper <AMQPSymbol> .wrapMap(_properties));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { (byte)_code.Value }));

            list.Constructor = constructor;

            return(list);
        }
        public override TLVList getArguments()
        {
            TLVList list = new TLVList();

            if (_role == null)
            {
                throw new MalformedMessageException("Disposition header's role can't be null");
            }

            if (_role.Value == RoleCodes.RECEIVER)
            {
                list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(true));
            }
            else
            {
                list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(false));
            }

            if (_first == null)
            {
                throw new MalformedMessageException("Transfer header's first can't be null");
            }

            list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap(_first));

            if (_last != null)
            {
                list.addElement(2, AMQPWrapper <AMQPSymbol> .wrap(_last));
            }

            if (_settled != null)
            {
                list.addElement(3, AMQPWrapper <AMQPSymbol> .wrap(_settled));
            }

            if (_state != null)
            {
                list.addElement(4, _state.getList());
            }

            if (_batchable != null)
            {
                list.addElement(5, AMQPWrapper <AMQPSymbol> .wrap(_batchable));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { (byte)_code }));

            list.Constructor = constructor;

            return(list);
        }
        public TLVAmqp getValue()
        {
            TLVList list = new TLVList();

            if (_sequence != null)
            {
                list = AMQPWrapper <Object> .wrapList(_sequence);
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x76 }));

            list.Constructor = constructor;

            return(list);
        }
Esempio n. 12
0
        public TLVAmqp getValue()
        {
            TLVMap map = new TLVMap();

            if (_annotations != null)
            {
                map = AMQPWrapper <Object> .wrapMap(_annotations);
            }

            DescribedConstructor constructor = new DescribedConstructor(map.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x71 }));

            map.Constructor = constructor;

            return(map);
        }
Esempio n. 13
0
        public TLVList getList()
        {
            TLVList list = new TLVList();

            if (_error != null)
            {
                list.addElement(0, _error.getList());
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x25 }));

            list.Constructor = constructor;

            return(list);
        }
Esempio n. 14
0
        public TLVAmqp getValue()
        {
            TLVMap map = new TLVMap();

            if (_properties != null)
            {
                map = AMQPWrapper <String> .wrapMap(_properties);
            }

            DescribedConstructor constructor = new DescribedConstructor(map.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x74 }));

            map.Constructor = constructor;

            return(map);
        }
        public override TLVList getArguments()
        {
            TLVList list = new TLVList();

            if (_mechanisms == null)
            {
                throw new MalformedMessageException("At least one SASL Mechanism must be specified");
            }

            list.addElement(0, AMQPWrapper <AMQPSymbol> .wrapArray(_mechanisms));

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x40 }));

            list.Constructor = constructor;

            return(list);
        }
Esempio n. 16
0
        public override TLVList getArguments()
        {
            TLVList list = new TLVList();

            if (_challenge == null)
            {
                throw new MalformedMessageException("SASL-Challenge header's challenge can't be null");
            }

            list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(_challenge));

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x42 }));

            list.Constructor = constructor;

            return(list);
        }
        public override TLVList getArguments()
        {
            TLVList list = new TLVList();

            if (_error != null)
            {
                list.addElement(0, _error.getList());
            }
            else
            {
                list.addElement(0, new TLVNull());
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { (byte)_code }));

            list.Constructor = constructor;

            return(list);
        }
        public TLVAmqp getValue()
        {
            TLVAmqp bin = null;

            if (_data != null)
            {
                bin = AMQPWrapper <AMQPSymbol> .wrap(_data);
            }
            else
            {
                bin = new TLVNull();
            }

            DescribedConstructor constructor = new DescribedConstructor(bin.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x75 }));

            bin.Constructor = constructor;

            return(bin);
        }
        private static SimpleConstructor getConstructor(IByteBuffer buf)
        {
            AMQPType          code        = AMQPType.NULL;
            SimpleConstructor constructor = null;
            byte codeByte = buf.ReadByte();

            if (codeByte == 0)
            {
                TLVAmqp descriptor = getTlv(buf);
                code        = (AMQPType)(buf.ReadByte() & 0x0ff);
                constructor = new DescribedConstructor(code, descriptor);
            }
            else
            {
                code        = (AMQPType)(codeByte & 0x0ff);
                constructor = new SimpleConstructor(code);
            }
            return(constructor);
        }
Esempio n. 20
0
        public TLVList getList()
        {
            TLVList list = new TLVList();

            if (_sectionNumber != null)
            {
                list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(_sectionNumber));
            }
            if (_sectionOffset != null)
            {
                list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap(_sectionOffset));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x23 }));

            list.Constructor = constructor;

            return(list);
        }
Esempio n. 21
0
        public override TLVList getArguments()
        {
            TLVList list = new TLVList();

            if (_outcomeCode == null)
            {
                throw new MalformedMessageException("SASL-Outcome header's code can't be null");
            }

            list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap((Int32)_outcomeCode.Value));

            if (_additionalData != null)
            {
                list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap(_additionalData));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x44 }));

            list.Constructor = constructor;

            return(list);
        }
Esempio n. 22
0
        public TLVList getList()
        {
            TLVList list = new TLVList();

            if (_deliveryFailed.HasValue)
            {
                list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(_deliveryFailed));
            }
            if (_undeliverableHere.HasValue)
            {
                list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap(_undeliverableHere));
            }
            if (_messageAnnotations != null)
            {
                list.addElement(2, AMQPWrapper <AMQPSymbol> .wrapMap(_messageAnnotations));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x27 }));

            list.Constructor = constructor;

            return(list);
        }
        public override TLVList getArguments()
        {
            TLVList list = new TLVList();

            if (_name == null)
            {
                throw new MalformedMessageException("Attach header's name can't be null");
            }
            list.addElement(0, AMQPWrapper <AMQPSymbol> .wrapString(_name));

            if (_handle == null)
            {
                throw new MalformedMessageException("Attach header's handle can't be null");
            }

            list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap(_handle));

            if (!_role.HasValue)
            {
                throw new MalformedMessageException("Attach header's role can't be null");
            }

            if (_role.Value == RoleCodes.RECEIVER)
            {
                list.addElement(2, AMQPWrapper <AMQPSymbol> .wrap(true));
            }
            else
            {
                list.addElement(2, AMQPWrapper <AMQPSymbol> .wrap(false));
            }

            if (_sndSettleMode.HasValue)
            {
                list.addElement(3, AMQPWrapper <AMQPSymbol> .wrap((short)_sndSettleMode.Value));
            }

            if (_rcvSettleMode.HasValue)
            {
                list.addElement(4, AMQPWrapper <AMQPSymbol> .wrap((short)_rcvSettleMode.Value));
            }

            if (_source != null)
            {
                list.addElement(5, _source.getList());
            }

            if (_target != null)
            {
                list.addElement(6, _target.getList());
            }

            if (_unsettled != null)
            {
                list.addElement(7, AMQPWrapper <AMQPSymbol> .wrapMap(_unsettled));
            }

            if (_incompleteUnsettled.HasValue)
            {
                list.addElement(8, AMQPWrapper <AMQPSymbol> .wrap(_incompleteUnsettled));
            }

            if (_initialDeliveryCount.HasValue)
            {
                list.addElement(9, AMQPWrapper <AMQPSymbol> .wrap(_initialDeliveryCount));
            }
            else if (_role.Value == RoleCodes.SENDER)
            {
                throw new MalformedMessageException("Sender's attach header must contain a non-null initial-delivery-count value");
            }

            if (_maxMessageSize.HasValue)
            {
                list.addElement(10, AMQPWrapper <AMQPSymbol> .wrap(_maxMessageSize));
            }

            if (_offeredCapabilities != null)
            {
                list.addElement(11, AMQPWrapper <AMQPSymbol> .wrapArray(_offeredCapabilities));
            }

            if (_desiredCapabilities != null)
            {
                list.addElement(12, AMQPWrapper <AMQPSymbol> .wrapArray(_desiredCapabilities));
            }

            if (_properties != null)
            {
                list.addElement(13, AMQPWrapper <AMQPSymbol> .wrapMap(_properties));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { (byte)_code }));

            list.Constructor = constructor;

            return(list);
        }
Esempio n. 24
0
        public override TLVList getArguments()
        {
            TLVList list = new TLVList();

            if (_nextIncomingId != null)
            {
                list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(_nextIncomingId));
            }

            if (_incomingWindow == null)
            {
                throw new MalformedMessageException("Flow header's incoming-window can't be null");
            }
            list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap(_incomingWindow));

            if (_nextOutgoingId == null)
            {
                throw new MalformedMessageException("Flow header's next-outgoing-id can't be null");
            }
            list.addElement(2, AMQPWrapper <AMQPSymbol> .wrap(_nextOutgoingId));

            if (_outgoingWindow == null)
            {
                throw new MalformedMessageException("Flow header's outgoing-window can't be null");
            }
            list.addElement(3, AMQPWrapper <AMQPSymbol> .wrap(_outgoingWindow));

            if (_handle != null)
            {
                list.addElement(4, AMQPWrapper <AMQPSymbol> .wrap(_handle));
            }

            if (_deliveryCount != null)
            {
                if (_handle != null)
                {
                    list.addElement(5, AMQPWrapper <AMQPSymbol> .wrap(_deliveryCount));
                }
                else
                {
                    throw new MalformedMessageException("Flow headers delivery-count can't be assigned when handle is not specified");
                }
            }

            if (_linkCredit != null)
            {
                if (_handle != null)
                {
                    list.addElement(6, AMQPWrapper <AMQPSymbol> .wrap(_linkCredit));
                }
                else
                {
                    throw new MalformedMessageException(
                              "Flow headers link-credit can't be assigned when handle is not specified");
                }
            }

            if (_avaliable != null)
            {
                if (_handle != null)
                {
                    list.addElement(7, AMQPWrapper <AMQPSymbol> .wrap(_avaliable));
                }
                else
                {
                    throw new MalformedMessageException(
                              "Flow headers avaliable can't be assigned when handle is not specified");
                }
            }

            if (_drain != null)
            {
                if (_handle != null)
                {
                    list.addElement(8, AMQPWrapper <AMQPSymbol> .wrap(_drain));
                }
                else
                {
                    throw new MalformedMessageException("Flow headers drain can't be assigned when handle is not specified");
                }
            }

            if (_echo != null)
            {
                list.addElement(9, AMQPWrapper <AMQPSymbol> .wrap(_echo));
            }

            if (_properties != null)
            {
                list.addElement(10, AMQPWrapper <AMQPSymbol> .wrapMap(_properties));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { (byte)_code }));

            list.Constructor = constructor;

            return(list);
        }
Esempio n. 25
0
        public override TLVList getArguments()
        {
            TLVList list = new TLVList();

            if (_handle == null)
            {
                throw new MalformedMessageException("Transfer header's handle can't be null");
            }

            list.addElement(0, AMQPWrapper <SectionCodes> .wrap(_handle));

            if (_deliveryId != null)
            {
                list.addElement(1, AMQPWrapper <SectionCodes> .wrap(_deliveryId));
            }

            if (_deliveryTag != null)
            {
                list.addElement(2, AMQPWrapper <SectionCodes> .wrap(_deliveryTag));
            }

            if (_messageFormat != null)
            {
                list.addElement(3, AMQPWrapper <SectionCodes> .wrap(_messageFormat.encode()));
            }

            if (_settled != null)
            {
                list.addElement(4, AMQPWrapper <SectionCodes> .wrap(_settled));
            }

            if (_more != null)
            {
                list.addElement(5, AMQPWrapper <SectionCodes> .wrap(_more));
            }

            if (_rcvSettleMode != null)
            {
                list.addElement(6, AMQPWrapper <SectionCodes> .wrap((Int32)_rcvSettleMode.Value));
            }

            if (_state != null)
            {
                list.addElement(7, _state.getList());
            }

            if (_resume != null)
            {
                list.addElement(8, AMQPWrapper <SectionCodes> .wrap(_resume));
            }

            if (_aborted != null)
            {
                list.addElement(9, AMQPWrapper <SectionCodes> .wrap(_aborted));
            }

            if (_batchable != null)
            {
                list.addElement(10, AMQPWrapper <SectionCodes> .wrap(_batchable));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { (byte)_code }));

            list.Constructor = constructor;

            return(list);
        }
        public override TLVList getArguments()
        {
            TLVList list = new TLVList();

            if (_containerId == null)
            {
                throw new MalformedMessageException("Open header's container id can't be null");
            }

            list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(_containerId));

            if (_hostname != null)
            {
                list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap(_hostname));
            }

            if (_maxFrameSize != null)
            {
                list.addElement(2, AMQPWrapper <AMQPSymbol> .wrap(_maxFrameSize));
            }

            if (_channelMax != null)
            {
                list.addElement(3, AMQPWrapper <AMQPSymbol> .wrap(_channelMax));
            }

            if (_idleTimeout != null)
            {
                list.addElement(4, AMQPWrapper <AMQPSymbol> .wrap(_idleTimeout));
            }

            if (_outgoingLocales != null)
            {
                list.addElement(5, AMQPWrapper <AMQPSymbol> .wrapArray(_outgoingLocales));
            }

            if (_incomingLocales != null)
            {
                list.addElement(6, AMQPWrapper <AMQPSymbol> .wrapArray(_incomingLocales));
            }

            if (_offeredCapabilities != null)
            {
                list.addElement(7, AMQPWrapper <AMQPSymbol> .wrapArray(_offeredCapabilities));
            }

            if (_desiredCapabilities != null)
            {
                list.addElement(8, AMQPWrapper <AMQPSymbol> .wrapArray(_desiredCapabilities));
            }

            if (_properties != null)
            {
                list.addElement(9, AMQPWrapper <AMQPSymbol> .wrapMap(_properties));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { (byte)_code }));

            list.Constructor = constructor;

            return(list);
        }
        public TLVAmqp getValue()
        {
            TLVList list = new TLVList();

            if (_messageId != null)
            {
                Object value = null;
                if (_messageId.getBinary() != null)
                {
                    value = _messageId.getBinary();
                }
                else if (_messageId.getLong() != null)
                {
                    value = _messageId.getLong();
                }
                else if (_messageId.getString() != null)
                {
                    value = _messageId.getString();
                }
                else if (_messageId.getUuid() != null)
                {
                    value = _messageId.getUuid();
                }
                list.addElement(0, AMQPWrapper <AMQPSymbol> .wrap(value));
            }

            if (_userId != null)
            {
                list.addElement(1, AMQPWrapper <AMQPSymbol> .wrap(_userId));
            }

            if (_to != null)
            {
                list.addElement(2, AMQPWrapper <AMQPSymbol> .wrap(_to));
            }

            if (_subject != null)
            {
                list.addElement(3, AMQPWrapper <AMQPSymbol> .wrap(_subject));
            }

            if (_replyTo != null)
            {
                list.addElement(4, AMQPWrapper <AMQPSymbol> .wrap(_replyTo));
            }

            if (_correlationId != null)
            {
                list.addElement(5, AMQPWrapper <AMQPSymbol> .wrap(_correlationId));
            }

            if (_contentType != null)
            {
                list.addElement(6, AMQPWrapper <AMQPSymbol> .wrap(_contentType));
            }

            if (_contentEncoding != null)
            {
                list.addElement(7, AMQPWrapper <AMQPSymbol> .wrap(_contentEncoding));
            }

            if (_absoluteExpiryTime != null)
            {
                list.addElement(8, AMQPWrapper <AMQPSymbol> .wrap(_absoluteExpiryTime));
            }

            if (_creationTime != null)
            {
                list.addElement(9, AMQPWrapper <AMQPSymbol> .wrap(_creationTime));
            }

            if (_groupId != null)
            {
                list.addElement(10, AMQPWrapper <AMQPSymbol> .wrap(_groupId));
            }

            if (_groupSequence != null)
            {
                list.addElement(11, AMQPWrapper <AMQPSymbol> .wrap(_groupSequence));
            }

            if (_replyToGroupId != null)
            {
                list.addElement(12, AMQPWrapper <AMQPSymbol> .wrap(_replyToGroupId));
            }

            DescribedConstructor constructor = new DescribedConstructor(list.Code, new TLVFixed(AMQPType.SMALL_ULONG, new byte[] { 0x73 }));

            list.Constructor = constructor;

            return(list);
        }