Lines Matching refs:rStrm
241 …tHandlerRef SheetDataContext::onCreateRecordContext( sal_Int32 nRecId, SequenceInputStream& rStrm ) in onCreateRecordContext() argument
246 if( nRecId == BIFF12_ID_ROW ) { importRow( rStrm ); return this; } in onCreateRecordContext()
252 … case BIFF12_ID_ARRAY: importArray( rStrm ); break; in onCreateRecordContext()
253 … case BIFF12_ID_CELL_BOOL: importCellBool( rStrm, CELLTYPE_VALUE ); break; in onCreateRecordContext()
254 … case BIFF12_ID_CELL_BLANK: importCellBlank( rStrm, CELLTYPE_VALUE ); break; in onCreateRecordContext()
255 … case BIFF12_ID_CELL_DOUBLE: importCellDouble( rStrm, CELLTYPE_VALUE ); break; in onCreateRecordContext()
256 … case BIFF12_ID_CELL_ERROR: importCellError( rStrm, CELLTYPE_VALUE ); break; in onCreateRecordContext()
257 … case BIFF12_ID_CELL_RK: importCellRk( rStrm, CELLTYPE_VALUE ); break; in onCreateRecordContext()
258 … case BIFF12_ID_CELL_RSTRING: importCellRString( rStrm, CELLTYPE_VALUE ); break; in onCreateRecordContext()
259 … case BIFF12_ID_CELL_SI: importCellSi( rStrm, CELLTYPE_VALUE ); break; in onCreateRecordContext()
260 … case BIFF12_ID_CELL_STRING: importCellString( rStrm, CELLTYPE_VALUE ); break; in onCreateRecordContext()
261 … case BIFF12_ID_DATATABLE: importDataTable( rStrm ); break; in onCreateRecordContext()
262 … case BIFF12_ID_FORMULA_BOOL: importCellBool( rStrm, CELLTYPE_FORMULA ); break; in onCreateRecordContext()
263 … case BIFF12_ID_FORMULA_DOUBLE: importCellDouble( rStrm, CELLTYPE_FORMULA ); break; in onCreateRecordContext()
264 … case BIFF12_ID_FORMULA_ERROR: importCellError( rStrm, CELLTYPE_FORMULA ); break; in onCreateRecordContext()
265 … case BIFF12_ID_FORMULA_STRING: importCellString( rStrm, CELLTYPE_FORMULA ); break; in onCreateRecordContext()
266 … case BIFF12_ID_MULTCELL_BOOL: importCellBool( rStrm, CELLTYPE_MULTI ); break; in onCreateRecordContext()
267 … case BIFF12_ID_MULTCELL_BLANK: importCellBlank( rStrm, CELLTYPE_MULTI ); break; in onCreateRecordContext()
268 … case BIFF12_ID_MULTCELL_DOUBLE: importCellDouble( rStrm, CELLTYPE_MULTI ); break; in onCreateRecordContext()
269 … case BIFF12_ID_MULTCELL_ERROR: importCellError( rStrm, CELLTYPE_MULTI ); break; in onCreateRecordContext()
270 … case BIFF12_ID_MULTCELL_RK: importCellRk( rStrm, CELLTYPE_MULTI ); break; in onCreateRecordContext()
271 … case BIFF12_ID_MULTCELL_RSTRING:importCellRString( rStrm, CELLTYPE_MULTI ); break; in onCreateRecordContext()
272 … case BIFF12_ID_MULTCELL_SI: importCellSi( rStrm, CELLTYPE_MULTI ); break; in onCreateRecordContext()
273 … case BIFF12_ID_MULTCELL_STRING: importCellString( rStrm, CELLTYPE_MULTI ); break; in onCreateRecordContext()
274 … case BIFF12_ID_SHAREDFMLA: importSharedFmla( rStrm ); break; in onCreateRecordContext()
360 void SheetDataContext::importRow( SequenceInputStream& rStrm ) in importRow() argument
366 rStrm >> maCurrPos.mnRow >> aModel.mnXfId >> nHeight >> nFlags1 >> nFlags2 >> nSpanCount; in importRow()
384 for( sal_Int32 nSpanIdx = 0; (nSpanIdx < nSpanCount) && !rStrm.isEof(); ++nSpanIdx ) in importRow()
387 rStrm >> nFirstCol >> nLastCol; in importRow()
395 bool SheetDataContext::readCellHeader( SequenceInputStream& rStrm, CellType eCellType ) in readCellHeader() argument
400 case CELLTYPE_FORMULA: rStrm >> maCurrPos.mnCol; break; in readCellHeader()
405 rStrm >> nXfId; in readCellHeader()
417 ApiTokenSequence SheetDataContext::readCellFormula( SequenceInputStream& rStrm ) in readCellFormula() argument
419 rStrm.skip( 2 ); in readCellFormula()
420 return mrFormulaParser.importFormula( maCellData.maCellAddr, FORMULATYPE_CELL, rStrm ); in readCellFormula()
423 bool SheetDataContext::readFormulaRef( SequenceInputStream& rStrm ) in readFormulaRef() argument
426 rStrm >> aRange; in readFormulaRef()
430 void SheetDataContext::importCellBool( SequenceInputStream& rStrm, CellType eCellType ) in importCellBool() argument
432 if( readCellHeader( rStrm, eCellType ) ) in importCellBool()
435 bool bValue = rStrm.readuInt8() != 0; in importCellBool()
437 mrSheetData.setFormulaCell( maCellData, readCellFormula( rStrm ) ); in importCellBool()
443 void SheetDataContext::importCellBlank( SequenceInputStream& rStrm, CellType eCellType ) in importCellBlank() argument
446 if( readCellHeader( rStrm, eCellType ) ) in importCellBlank()
450 void SheetDataContext::importCellDouble( SequenceInputStream& rStrm, CellType eCellType ) in importCellDouble() argument
452 if( readCellHeader( rStrm, eCellType ) ) in importCellDouble()
455 double fValue = rStrm.readDouble(); in importCellDouble()
457 mrSheetData.setFormulaCell( maCellData, readCellFormula( rStrm ) ); in importCellDouble()
463 void SheetDataContext::importCellError( SequenceInputStream& rStrm, CellType eCellType ) in importCellError() argument
465 if( readCellHeader( rStrm, eCellType ) ) in importCellError()
468 sal_uInt8 nErrorCode = rStrm.readuInt8(); in importCellError()
470 mrSheetData.setFormulaCell( maCellData, readCellFormula( rStrm ) ); in importCellError()
476 void SheetDataContext::importCellRk( SequenceInputStream& rStrm, CellType eCellType ) in importCellRk() argument
479 if( readCellHeader( rStrm, eCellType ) ) in importCellRk()
482 mrSheetData.setValueCell( maCellData, BiffHelper::calcDoubleFromRk( rStrm.readInt32() ) ); in importCellRk()
486 void SheetDataContext::importCellRString( SequenceInputStream& rStrm, CellType eCellType ) in importCellRString() argument
489 if( readCellHeader( rStrm, eCellType ) ) in importCellRString()
493 xString->importString( rStrm, true ); in importCellRString()
499 void SheetDataContext::importCellSi( SequenceInputStream& rStrm, CellType eCellType ) in importCellSi() argument
502 if( readCellHeader( rStrm, eCellType ) ) in importCellSi()
505 mrSheetData.setStringCell( maCellData, rStrm.readInt32() ); in importCellSi()
509 void SheetDataContext::importCellString( SequenceInputStream& rStrm, CellType eCellType ) in importCellString() argument
511 if( readCellHeader( rStrm, eCellType ) ) in importCellString()
516 xString->importString( rStrm, false ); in importCellString()
519 mrSheetData.setFormulaCell( maCellData, readCellFormula( rStrm ) ); in importCellString()
525 void SheetDataContext::importArray( SequenceInputStream& rStrm ) in importArray() argument
527 if( readFormulaRef( rStrm ) && maFmlaData.isValidArrayRef( maCellData.maCellAddr ) ) in importArray()
529 rStrm.skip( 1 ); in importArray()
530 …equence aTokens = mrFormulaParser.importFormula( maCellData.maCellAddr, FORMULATYPE_ARRAY, rStrm ); in importArray()
535 void SheetDataContext::importDataTable( SequenceInputStream& rStrm ) in importDataTable() argument
537 if( readFormulaRef( rStrm ) ) in importDataTable()
541 rStrm >> aRef1 >> aRef2 >> nFlags; in importDataTable()
552 void SheetDataContext::importSharedFmla( SequenceInputStream& rStrm ) in importSharedFmla() argument
554 if( readFormulaRef( rStrm ) && maFmlaData.isValidSharedRef( maCellData.maCellAddr ) ) in importSharedFmla()
556 …aTokens = mrFormulaParser.importFormula( maCellData.maCellAddr, FORMULATYPE_SHAREDFORMULA, rStrm ); in importSharedFmla()
589 void BiffSheetDataContext::importRecord( BiffInputStream& rStrm ) in importRecord() argument
591 sal_uInt16 nRecId = rStrm.getRecId(); in importRecord()
596 case BIFF3_ID_ARRAY: importArray( rStrm ); break; in importRecord()
598 case BIFF3_ID_BLANK: importBlank( rStrm ); break; in importRecord()
600 case BIFF3_ID_BOOLERR: importBoolErr( rStrm ); break; in importRecord()
601 case BIFF2_ID_INTEGER: importInteger( rStrm ); break; in importRecord()
602 case BIFF_ID_IXFE: rStrm >> mnBiff2XfId; break; in importRecord()
604 case BIFF3_ID_LABEL: importLabel( rStrm ); break; in importRecord()
606 case BIFF3_ID_NUMBER: importNumber( rStrm ); break; in importRecord()
607 case BIFF_ID_RK: importRk( rStrm ); break; in importRecord()
614 case BIFF2_ID_DATATABLE: importDataTable( rStrm ); break; in importRecord()
615 case BIFF2_ID_DATATABLE2: importDataTable( rStrm ); break; in importRecord()
616 case BIFF2_ID_FORMULA: importFormula( rStrm ); break; in importRecord()
617 case BIFF2_ID_ROW: importRow( rStrm ); break; in importRecord()
623 case BIFF3_ID_DATATABLE: importDataTable( rStrm ); break; in importRecord()
624 case BIFF3_ID_FORMULA: importFormula( rStrm ); break; in importRecord()
625 case BIFF3_ID_ROW: importRow( rStrm ); break; in importRecord()
631 case BIFF3_ID_DATATABLE: importDataTable( rStrm ); break; in importRecord()
632 case BIFF4_ID_FORMULA: importFormula( rStrm ); break; in importRecord()
633 case BIFF3_ID_ROW: importRow( rStrm ); break; in importRecord()
639 case BIFF3_ID_DATATABLE: importDataTable( rStrm ); break; in importRecord()
642 case BIFF5_ID_FORMULA: importFormula( rStrm ); break; in importRecord()
643 case BIFF_ID_MULTBLANK: importMultBlank( rStrm ); break; in importRecord()
644 case BIFF_ID_MULTRK: importMultRk( rStrm ); break; in importRecord()
645 case BIFF3_ID_ROW: importRow( rStrm ); break; in importRecord()
646 case BIFF_ID_RSTRING: importLabel( rStrm ); break; in importRecord()
647 case BIFF_ID_SHAREDFMLA: importSharedFmla( rStrm ); break; in importRecord()
653 case BIFF3_ID_DATATABLE: importDataTable( rStrm ); break; in importRecord()
656 case BIFF5_ID_FORMULA: importFormula( rStrm ); break; in importRecord()
657 case BIFF_ID_LABELSST: importLabelSst( rStrm ); break; in importRecord()
658 case BIFF_ID_MULTBLANK: importMultBlank( rStrm ); break; in importRecord()
659 case BIFF_ID_MULTRK: importMultRk( rStrm ); break; in importRecord()
660 case BIFF3_ID_ROW: importRow( rStrm ); break; in importRecord()
661 case BIFF_ID_RSTRING: importLabel( rStrm ); break; in importRecord()
662 case BIFF_ID_SHAREDFMLA: importSharedFmla( rStrm ); break; in importRecord()
674 void BiffSheetDataContext::importRow( BiffInputStream& rStrm ) in importRow() argument
678 rStrm >> nRow >> nFirstUsedCol >> nFirstFreeCol >> nHeight; in importRow()
681 rStrm.skip( 2 ); in importRow()
682 aModel.mbCustomFormat = rStrm.readuInt8() == BIFF2_ROW_CUSTOMFORMAT; in importRow()
685 rStrm.skip( 5 ); in importRow()
686 aModel.mnXfId = rStrm.readuInt16(); in importRow()
691 rStrm.skip( 4 ); in importRow()
692 sal_uInt32 nFlags = rStrm.readuInt32(); in importRow()
719 bool BiffSheetDataContext::readCellXfId( BiffInputStream& rStrm, const BinAddress& rAddr, bool bBif… in readCellXfId() argument
738 rStrm >> nFlags1 >> nFlags2 >> nFlags3; in readCellXfId()
762 maCellData.mnXfId = rStrm.readuInt16(); in readCellXfId()
768 bool BiffSheetDataContext::readCellHeader( BiffInputStream& rStrm, bool bBiff2 ) in readCellHeader() argument
771 rStrm >> aAddr; in readCellHeader()
772 return readCellXfId( rStrm, aAddr, bBiff2 ); in readCellHeader()
775 bool BiffSheetDataContext::readFormulaRef( BiffInputStream& rStrm ) in readFormulaRef() argument
778 aRange.read( rStrm, false ); // columns always 8-bit in readFormulaRef()
782 void BiffSheetDataContext::importBlank( BiffInputStream& rStrm ) in importBlank() argument
784 if( readCellHeader( rStrm, rStrm.getRecId() == BIFF2_ID_BLANK ) ) in importBlank()
788 void BiffSheetDataContext::importBoolErr( BiffInputStream& rStrm ) in importBoolErr() argument
790 if( readCellHeader( rStrm, rStrm.getRecId() == BIFF2_ID_BOOLERR ) ) in importBoolErr()
793 rStrm >> nValue >> nType; in importBoolErr()
812 void BiffSheetDataContext::importFormula( BiffInputStream& rStrm ) in importFormula() argument
814 if( readCellHeader( rStrm, getBiff() == BIFF2 ) ) in importFormula()
817 rStrm.skip( mnFormulaSkipSize ); in importFormula()
818 …Sequence aTokens = mrFormulaParser.importFormula( maCellData.maCellAddr, FORMULATYPE_CELL, rStrm ); in importFormula()
823 void BiffSheetDataContext::importInteger( BiffInputStream& rStrm ) in importInteger() argument
825 if( readCellHeader( rStrm, true ) ) in importInteger()
828 mrSheetData.setValueCell( maCellData, rStrm.readuInt16() ); in importInteger()
832 void BiffSheetDataContext::importLabel( BiffInputStream& rStrm ) in importLabel() argument
841 bool bBiff2Xf = rStrm.getRecId() == BIFF2_ID_LABEL; in importLabel()
842 if( readCellHeader( rStrm, bBiff2Xf ) ) in importLabel()
849 xString->importUniString( rStrm ); in importLabel()
860 if( rStrm.getRecId() == BIFF_ID_RSTRING ) in importLabel()
866 xString->importByteString( rStrm, eTextEnc, nFlags ); in importLabel()
873 OUString aText = rStrm.readByteStringUC( !bBiff2Xf, eTextEnc ); in importLabel()
880 void BiffSheetDataContext::importLabelSst( BiffInputStream& rStrm ) in importLabelSst() argument
882 if( readCellHeader( rStrm, false ) ) in importLabelSst()
885 mrSheetData.setStringCell( maCellData, rStrm.readInt32() ); in importLabelSst()
889 void BiffSheetDataContext::importMultBlank( BiffInputStream& rStrm ) in importMultBlank() argument
893 for( rStrm >> aAddr; bValidAddr && (rStrm.getRemaining() > 2); ++aAddr.mnCol ) in importMultBlank()
894 if( (bValidAddr = readCellXfId( rStrm, aAddr, false )) == true ) in importMultBlank()
898 void BiffSheetDataContext::importMultRk( BiffInputStream& rStrm ) in importMultRk() argument
902 for( rStrm >> aAddr; bValidAddr && (rStrm.getRemaining() > 2); ++aAddr.mnCol ) in importMultRk()
904 if( (bValidAddr = readCellXfId( rStrm, aAddr, false )) == true ) in importMultRk()
907 sal_Int32 nRkValue = rStrm.readInt32(); in importMultRk()
913 void BiffSheetDataContext::importNumber( BiffInputStream& rStrm ) in importNumber() argument
915 if( readCellHeader( rStrm, rStrm.getRecId() == BIFF2_ID_NUMBER ) ) in importNumber()
918 mrSheetData.setValueCell( maCellData, rStrm.readDouble() ); in importNumber()
922 void BiffSheetDataContext::importRk( BiffInputStream& rStrm ) in importRk() argument
924 if( readCellHeader( rStrm, false ) ) in importRk()
927 mrSheetData.setValueCell( maCellData, BiffHelper::calcDoubleFromRk( rStrm.readInt32() ) ); in importRk()
931 void BiffSheetDataContext::importArray( BiffInputStream& rStrm ) in importArray() argument
933 if( readFormulaRef( rStrm ) && maFmlaData.isValidArrayRef( maCellData.maCellAddr ) ) in importArray()
935 rStrm.skip( mnArraySkipSize ); in importArray()
936 …equence aTokens = mrFormulaParser.importFormula( maCellData.maCellAddr, FORMULATYPE_ARRAY, rStrm ); in importArray()
941 void BiffSheetDataContext::importDataTable( BiffInputStream& rStrm ) in importDataTable() argument
943 if( readFormulaRef( rStrm ) ) in importDataTable()
947 switch( rStrm.getRecId() ) in importDataTable()
950 rStrm.skip( 1 ); in importDataTable()
951 aModel.mbRowTable = rStrm.readuInt8() != 0; in importDataTable()
953 rStrm >> aRef1; in importDataTable()
956 rStrm.skip( 2 ); in importDataTable()
958 rStrm >> aRef1 >> aRef2; in importDataTable()
963 rStrm >> nFlags >> aRef1 >> aRef2; in importDataTable()
979 void BiffSheetDataContext::importSharedFmla( BiffInputStream& rStrm ) in importSharedFmla() argument
981 if( readFormulaRef( rStrm ) && maFmlaData.isValidSharedRef( maCellData.maCellAddr ) ) in importSharedFmla()
983 rStrm.skip( 2 ); // flags in importSharedFmla()
984 …aTokens = mrFormulaParser.importFormula( maCellData.maCellAddr, FORMULATYPE_SHAREDFORMULA, rStrm ); in importSharedFmla()