Пример #1
0
 public bool MoveNext()
 {
     if (readerIndex == 8 && readerIndex == rawData.Length) return false;
     if (currentBlock.MoveNext())
     {
         this.CurrentObject = currentBlock.Current;
         this.currentType = currentBlock.currentType;
         return true;
     }
     this.currentBlock = ReadDataBlock();
     return this.MoveNext();
 }
Пример #2
0
 private XlTableDataBlock ReadDataBlock()
 {
     XlTableDataBlock rValue = new XlTableDataBlock();
     rValue.TableDataType =
         System.BitConverter.ToInt16(new byte[] { rawData[readerIndex], rawData[readerIndex + 1] }, 0);
     readerIndex += 2;
     rValue.DataSize =
         System.BitConverter.ToInt16(new byte[] { rawData[readerIndex], rawData[readerIndex + 1] }, 0);
     readerIndex += 2;
     rValue.data = new byte[rValue.DataSize];
     Array.Copy(rawData, readerIndex, rValue.data, 0, rValue.DataSize);
     readerIndex += rValue.DataSize;
     return rValue;
 }
Пример #3
0
        private XlTableDataBlock ReadDataBlock()
        {
            XlTableDataBlock rValue = new XlTableDataBlock();

            rValue.TableDataType =
                System.BitConverter.ToInt16(new byte[] { rawData[readerIndex], rawData[readerIndex + 1] }, 0);
            readerIndex    += 2;
            rValue.DataSize =
                System.BitConverter.ToInt16(new byte[] { rawData[readerIndex], rawData[readerIndex + 1] }, 0);
            readerIndex += 2;
            rValue.data  = new byte[rValue.DataSize];
            Array.Copy(rawData, readerIndex, rValue.data, 0, rValue.DataSize);
            readerIndex += rValue.DataSize;
            return(rValue);
        }
Пример #4
0
 public bool MoveNext()
 {
     if (readerIndex == 8 && readerIndex == rawData.Length)
     {
         return(false);
     }
     if (currentBlock.MoveNext())
     {
         this.CurrentObject = currentBlock.Current;
         this.currentType   = currentBlock.currentType;
         return(true);
     }
     this.currentBlock = ReadDataBlock();
     return(this.MoveNext());
 }
Пример #5
0
 public XLTableTyped(byte[] rawData)
 {
     this.rawData      = rawData;
     readerIndex       = 8;
     this.currentBlock = ReadDataBlock();
 }
Пример #6
0
 public XLTableTyped(byte[] rawData)
 {
     this.rawData = rawData;
     readerIndex = 8;
     this.currentBlock = ReadDataBlock();
 }