Beispiel #1
0
        public void TestLoad()
        {
            SeriesIndexRecord record = new SeriesIndexRecord(TestcaseRecordInputStream.Create(0x1065, data));


            Assert.AreEqual((short)3, record.Index);


            Assert.AreEqual(6, record.RecordSize);
        }
        public void TestLoad()
        {
            SeriesIndexRecord record = new SeriesIndexRecord(TestcaseRecordInputStream.Create(0x1065, data));


            Assert.AreEqual((short)3, record.Index);


            Assert.AreEqual(6, record.RecordSize);
        }
        public void TestStore()
        {
            SeriesIndexRecord record = new SeriesIndexRecord();



            record.Index=((short)3);


            byte[] recordBytes = record.Serialize();
            Assert.AreEqual(recordBytes.Length - 4, data.Length);
            for (int i = 0; i < data.Length; i++)
                Assert.AreEqual(data[i], recordBytes[i + 4], "At offset " + i);
        }
 public SeriesDataAggregate(RecordStream rs)
 {
     dimensions = (DimensionsRecord)rs.GetNext();
     while (rs.PeekNextChartSid() == SeriesIndexRecord.sid)
     {
         SeriesIndexRecord siIndex = (SeriesIndexRecord)rs.GetNext();
         int           sid         = rs.PeekNextChartSid();
         List <Record> dataList    = new List <Record>();
         while (sid == NumberRecord.sid || sid == BoolErrRecord.sid || sid == BlankRecord.sid || sid == LabelRecord.sid)
         {
             dataList.Add(rs.GetNext());
         }
         dicData.Add(siIndex, dataList);
     }
 }
Beispiel #5
0
        public void TestStore()
        {
            SeriesIndexRecord record = new SeriesIndexRecord();



            record.Index = ((short)3);


            byte[] recordBytes = record.Serialize();
            Assert.AreEqual(recordBytes.Length - 4, data.Length);
            for (int i = 0; i < data.Length; i++)
            {
                Assert.AreEqual(data[i], recordBytes[i + 4], "At offset " + i);
            }
        }
Beispiel #6
0
 private SeriesIndexRecord CreateSeriesIndexRecord(int index)
 {
     SeriesIndexRecord r = new SeriesIndexRecord();
     r.Index = ((short)index);
     return r;
 }