25 #include <com/sun/star/uno/Sequence.h>
28 namespace oox {
class SequenceInputStream; }
40 explicit BinAddress( sal_Int32 nCol, sal_Int32 nRow ) : mnCol( nCol ), mnRow( nRow ) {}
68 orRange.
read( rStrm );
78 ::std::vector< BinRange >::const_iterator
begin()
const {
return mvRanges.begin(); }
79 ::std::vector< BinRange >::const_iterator
end()
const {
return mvRanges.end(); }
89 orRanges.
read( rStrm );
120 sal_Int32& ornColumn, sal_Int32& ornRow,
121 const OUString& rString,
122 sal_Int32 nStart = 0,
126 sal_Int32& ornColumn, sal_Int32& ornRow,
const char* pStr );
146 sal_Int32& ornStartColumn, sal_Int32& ornStartRow,
147 sal_Int32& ornEndColumn, sal_Int32& ornEndRow,
148 const OUString& rString,
149 sal_Int32 nStart = 0 );
172 bool checkCol( sal_Int32 nCol,
bool bTrackOverflow );
181 bool checkRow( sal_Int32 nRow,
bool bTrackOverflow );
190 bool checkTab( sal_Int16 nSheet,
bool bTrackOverflow );
201 bool bTrackOverflow );
213 const OUString& rString,
217 ScAddress& orAddress,
const char* pStr, sal_Int16 nSheet );
230 const OUString& rString,
232 bool bTrackOverflow );
236 const char* pStr, sal_Int16 nSheet,
bool bTrackOverflow );
246 const OUString& rString,
248 bool bTrackOverflow );
275 bool bTrackOverflow );
287 bool bTrackOverflow );
306 bool bAllowOverflow,
bool bTrackOverflow );
336 bool bAllowOverflow,
bool bTrackOverflow );
348 const OUString& rString,
377 const OUString& rString,
379 bool bAllowOverflow,
bool bTrackOverflow );
419 bool bAllowOverflow,
bool bTrackOverflow );
433 bool bTrackOverflow );
451 const OUString& rString,
453 bool bTrackOverflow );
473 bool bTrackOverflow );
481 static css::uno::Sequence<css::table::CellRangeAddress>
490 sal_Int16 nMaxXlsTab, sal_Int32 nMaxXlsCol, sal_Int32 nMaxXlsRow );
static css::uno::Sequence< css::table::CellRangeAddress > toApiSequence(const ScRangeList &orRanges)
Converts the passed range list to a sequence of cell range addresses.
Helper class to provide access to global workbook data.
bool checkCellRange(const ScRange &rRange, bool bAllowOverflow, bool bTrackOverflow)
Checks the passed cell range if it fits into the spreadsheet limits.
bool checkCellAddress(const ScAddress &rAddress, bool bTrackOverflow)
Checks the passed cell address if it fits into the spreadsheet limits.
::std::vector< BinRange >::const_iterator end() const
bool checkCol(sal_Int32 nCol, bool bTrackOverflow)
Checks if the passed column index is valid.
A 2D cell range address list for binary filters.
A 2D cell address struct for binary filters.
bool validateCellRange(ScRange &orRange, bool bAllowOverflow, bool bTrackOverflow)
Checks the passed cell range, may try to fit it to current sheet limits.
A 2D cell range address struct for binary filters.
ScAddress maMaxPos
Maximum valid cell address in Excel.
const ScAddress & getMaxApiAddress() const
Returns the biggest valid cell address in the own Calc document.
static bool parseOoxAddress2d(sal_Int32 &ornColumn, sal_Int32 &ornRow, const OUString &rString, sal_Int32 nStart=0, sal_Int32 nLength=SAL_MAX_INT32)
Tries to parse the passed string for a 2d cell address in A1 notation.
bool isRowOverflow() const
bool isTabOverflow() const
::std::vector< BinRange >::const_iterator begin() const
static bool convertToCellRangeUnchecked(ScRange &orRange, const OUString &rString, sal_Int16 nSheet)
Converts the passed string to a cell range address, without checking any sheet limits.
bool mbColOverflow
Maximum valid cell address in Calc/Excel.
bool isColOverflow() const
::std::vector< BinRange > mvRanges
bool convertToCellAddress(ScAddress &orAddress, const OUString &rString, sal_Int16 nSheet, bool bTrackOverflow)
Tries to convert the passed string to a single cell address.
bool checkTab(sal_Int16 nSheet, bool bTrackOverflow)
Checks if the passed sheet index is valid.
static bool parseOoxRange2d(sal_Int32 &ornStartColumn, sal_Int32 &ornStartRow, sal_Int32 &ornEndColumn, sal_Int32 &ornEndRow, const OUString &rString, sal_Int32 nStart=0)
Tries to parse the passed string for a 2d cell range in A1 notation.
void read(SequenceInputStream &rStrm)
bool mbRowOverflow
Flag for "columns overflow".
SequenceInputStream & operator>>(SequenceInputStream &rStrm, BinAddress &orPos)
bool operator<(const BinAddress &rL, const BinAddress &rR)
bool checkRow(sal_Int32 nRow, bool bTrackOverflow)
Checks if the passed row index is valid.
void convertToCellRangeList(ScRangeList &orRanges, const OUString &rString, sal_Int16 nSheet, bool bTrackOverflow)
Tries to convert the passed string to a cell range list.
bool convertToCellRange(ScRange &orRange, const OUString &rString, sal_Int16 nSheet, bool bAllowOverflow, bool bTrackOverflow)
Tries to convert the passed string to a cell range address.
BinAddress(const ScAddress &rAddr)
void initializeMaxPos(sal_Int16 nMaxXlsTab, sal_Int32 nMaxXlsCol, sal_Int32 nMaxXlsRow)
bool mbTabOverflow
Flag for "rows overflow".
const ScAddress & getMaxAddress() const
Returns the biggest valid cell address in both Calc and the imported/exported Excel document...
BinAddress(sal_Int32 nCol, sal_Int32 nRow)
Converter for cell addresses and cell ranges for OOXML and BIFF filters.
ScAddress createValidCellAddress(const OUString &rString, sal_Int16 nSheet, bool bTrackOverflow)
Returns a valid cell address by moving it into allowed dimensions.
AddressConverter(const WorkbookHelper &rHelper)
void read(SequenceInputStream &rStrm)
void validateCellRangeList(ScRangeList &orRanges, bool bTrackOverflow)
Tries to restrict the passed cell range list to current sheet limits.
ScAddress maMaxXlsPos
Maximum valid cell address in Calc.
static bool convertToCellAddressUnchecked(ScAddress &orAddress, const OUString &rString, sal_Int16 nSheet)
Converts the passed string to a single cell address, without checking any sheet limits.
void read(SequenceInputStream &rStrm)
const ScAddress & getMaxXlsAddress() const
Returns the biggest valid cell address in the imported/exported Excel document.