Beispiel #1
0
            public E_RABDataForwardingItem Decode(BitArrayInputStream input)
            {
                int num;
                E_RABDataForwardingItem item = new E_RABDataForwardingItem();

                item.InitDefaults();
                BitMaskStream stream = (input.ReadBit() != 0) ? new BitMaskStream(input, 5) : new BitMaskStream(input, 5);

                input.ReadBit();
                item.e_RAB_ID = input.ReadBits(4);
                if (stream.Read())
                {
                    input.ReadBit();
                    num = input.ReadBits(8);
                    input.skipUnreadedBits();
                    item.dL_transportLayerAddress = input.ReadBitString(num + 1);
                }
                if (stream.Read())
                {
                    input.skipUnreadedBits();
                    item.dL_gTP_TEID = input.readOctetString(4);
                }
                if (stream.Read())
                {
                    input.ReadBit();
                    num = input.ReadBits(8);
                    input.skipUnreadedBits();
                    item.uL_TransportLayerAddress = input.ReadBitString(num + 1);
                }
                if (stream.Read())
                {
                    input.skipUnreadedBits();
                    item.uL_GTP_TEID = input.readOctetString(4);
                }
                if (stream.Read())
                {
                    input.skipUnreadedBits();
                    item.iE_Extensions = new List <ProtocolExtensionField>();
                    int nBits = 0x10;
                    int num5  = input.ReadBits(nBits) + 1;
                    for (int i = 0; i < num5; i++)
                    {
                        ProtocolExtensionField field = ProtocolExtensionField.PerDecoder.Instance.Decode(input);
                        item.iE_Extensions.Add(field);
                    }
                }
                return(item);
            }
Beispiel #2
0
 public E_RABDataForwardingItem Decode(BitArrayInputStream input)
 {
     int num;
     E_RABDataForwardingItem item = new E_RABDataForwardingItem();
     item.InitDefaults();
     BitMaskStream stream = (input.ReadBit() != 0) ? new BitMaskStream(input, 5) : new BitMaskStream(input, 5);
     input.ReadBit();
     item.e_RAB_ID = input.ReadBits(4);
     if (stream.Read())
     {
         input.ReadBit();
         num = input.ReadBits(8);
         input.skipUnreadedBits();
         item.dL_transportLayerAddress = input.ReadBitString(num + 1);
     }
     if (stream.Read())
     {
         input.skipUnreadedBits();
         item.dL_gTP_TEID = input.readOctetString(4);
     }
     if (stream.Read())
     {
         input.ReadBit();
         num = input.ReadBits(8);
         input.skipUnreadedBits();
         item.uL_TransportLayerAddress = input.ReadBitString(num + 1);
     }
     if (stream.Read())
     {
         input.skipUnreadedBits();
         item.uL_GTP_TEID = input.readOctetString(4);
     }
     if (stream.Read())
     {
         input.skipUnreadedBits();
         item.iE_Extensions = new List<ProtocolExtensionField>();
         int nBits = 0x10;
         int num5 = input.ReadBits(nBits) + 1;
         for (int i = 0; i < num5; i++)
         {
             ProtocolExtensionField field = ProtocolExtensionField.PerDecoder.Instance.Decode(input);
             item.iE_Extensions.Add(field);
         }
     }
     return item;
 }