Пример #1
0
        public override object Clone()
        {
            ChartFRTInfoRecord record = new ChartFRTInfoRecord();

            record.grbitFrt      = this.grbitFrt;
            record.rgCFRTID      = new CFRTID[this.rgCFRTID.Length];
            record.rt            = this.rt;
            record.verOriginator = this.verOriginator;
            record.verWriter     = verWriter;

            for (int i = 0; i < this.rgCFRTID.Length; i++)
            {
                record.rgCFRTID[i] = (CFRTID)this.rgCFRTID[i].Clone();
            }

            return(record);
        }
Пример #2
0
 private static ChartFRTInfoRecord CreateChartFRTInfoRecord()
 {
     ChartFRTInfoRecord retval = new ChartFRTInfoRecord();
     return retval;
 }
Пример #3
0
        public InternalChart(RecordStream rs)
        {
            _plsRecords = new List<PLSAggregate>();
            records = new List<RecordBase>(128);

            if (rs.PeekNextSid() != BOFRecord.sid)
            {
                throw new Exception("BOF record expected");
            }
            BOFRecord bof = (BOFRecord)rs.GetNext();
            if (bof.Type != BOFRecord.TYPE_CHART)
            {
                throw new RuntimeException("Bad BOF record type");
            }

            records.Add(bof);
            while (rs.HasNext())
            {
                int recSid = rs.PeekNextSid();

                Record.Record rec = rs.GetNext();
                if (recSid == EOFRecord.sid)
                {
                    records.Add(rec);
                    break;
                }

                if (recSid == ChartRecord.sid)
                {

                    continue;
                }

                if (recSid == ChartFRTInfoRecord.sid)
                {
                    _chartFrtInfo = (ChartFRTInfoRecord)rec;
                }
                else if (recSid == HeaderRecord.sid)
                {
                    header = (HeaderRecord)rec;
                }
                else if (recSid == FooterRecord.sid)
                {
                    footer = (FooterRecord)rec;
                }
                else if (recSid == HCenterRecord.sid)
                {
                    _hCenter = (HCenterRecord)rec;
                }
                else if (recSid == VCenterRecord.sid)
                {
                    _vCenter = (VCenterRecord)rec;
                }
                else if (recSid == LeftMarginRecord.sid)
                {
                    _leftMargin = (LeftMarginRecord)rec;
                }
                else if (recSid == RightMarginRecord.sid)
                {
                    _rightMargin = (RightMarginRecord)rec;
                }
                else if (recSid == TopMarginRecord.sid)
                {
                    _topMargin = (TopMarginRecord)rec;
                }
                else if (recSid == BottomMarginRecord.sid)
                {
                    _bottomMargin = (BottomMarginRecord)rec;
                }
                else if (recSid == UnknownRecord.PLS_004D) // PLS
                {
                    PLSAggregate pls = new PLSAggregate(rs);
                    PLSAggregateVisitor rv = new PLSAggregateVisitor(records);
                    pls.VisitContainedRecords(rv);
                    _plsRecords.Add(pls);

                    continue;
                }
                else if (recSid == PrintSetupRecord.sid)
                {
                    printSetup = (PrintSetupRecord)rec;
                }
                else if (recSid == PrintSizeRecord.sid)
                {
                    _printSize = (PrintSizeRecord)rec;
                }
                else if (recSid == HeaderFooterRecord.sid)
                {
                    HeaderFooterRecord hf = (HeaderFooterRecord)rec;
                    if (hf.IsCurrentSheet)
                        _headerFooter = hf;
                    else
                        _sviewHeaderFooters.Add(hf);
                }
                else if (recSid == ProtectRecord.sid)
                {
                    _protect = (ProtectRecord)rec;
                }
                records.Add(rec);
            }
            
        }
Пример #4
0
        public override object Clone()
        {
            ChartFRTInfoRecord record = new ChartFRTInfoRecord();

            record.grbitFrt = this.grbitFrt;
            record.rgCFRTID = new CFRTID[this.rgCFRTID.Length];
            record.rt = this.rt;
            record.verOriginator = this.verOriginator;
            record.verWriter = verWriter;

            for (int i = 0; i < this.rgCFRTID.Length; i++)
                record.rgCFRTID[i] = (CFRTID)this.rgCFRTID[i].Clone();

            return record;
        }