예제 #1
0
 public BINValue this[BINValue value]
 {
     get
     {
         return(this.Values[value]);
     }
 }
예제 #2
0
        public BINOptional(BinaryReader br, IBINValue parent)
        {
            this.Parent = parent;
            this.Type   = BINUtilities.UnpackType((BINValueType)br.ReadByte());
            byte valueCount = br.ReadByte(); //????

            if (valueCount > 1)
            {
                throw new Exception("Encountered an Optional value with Value Count: " + valueCount);
            }

            if (valueCount == 1)
            {
                this.Value = new BINValue(br, this, this.Type);
            }
        }
예제 #3
0
        public BINStructure(BinaryReader br, BINValue parent)
        {
            this.Parent = parent;

            this.Property = br.ReadUInt32();
            if (this.Property == 0)
            {
                return;
            }

            uint   size       = br.ReadUInt32();
            ushort valueCount = br.ReadUInt16();

            for (int i = 0; i < valueCount; i++)
            {
                this.Values.Add(new BINValue(br, this));
            }
        }