diff options
author | Kohei Yoshida <kohei.yoshida@suse.com> | 2011-11-14 15:04:41 -0500 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@suse.com> | 2011-11-14 17:05:59 -0500 |
commit | 3b58e5871f6da7be54dad5c1da1c0f0a8378ad73 (patch) | |
tree | 1db0e1be5a2fd00997b542476b894736c161f387 /sc | |
parent | 05dc62da44f0853bebf68e6f6c695900090a15ba (diff) |
Marking methods const where possible.
Diffstat (limited to 'sc')
-rw-r--r-- | sc/inc/table.hxx | 4 | ||||
-rw-r--r-- | sc/source/core/data/table2.cxx | 4 | ||||
-rw-r--r-- | sc/source/core/data/table3.cxx | 6 |
3 files changed, 7 insertions, 7 deletions
diff --git a/sc/inc/table.hxx b/sc/inc/table.hxx index c7f06170a4af..041cdaa7afb6 100644 --- a/sc/inc/table.hxx +++ b/sc/inc/table.hxx @@ -312,14 +312,14 @@ public: void SetError( SCCOL nCol, SCROW nRow, sal_uInt16 nError); void GetString( SCCOL nCol, SCROW nRow, rtl::OUString& rString ); - void GetInputString( SCCOL nCol, SCROW nRow, rtl::OUString& rString ); + void GetInputString( SCCOL nCol, SCROW nRow, rtl::OUString& rString ) const; double GetValue( const ScAddress& rPos ) const { return ValidColRow(rPos.Col(),rPos.Row()) ? aCol[rPos.Col()].GetValue( rPos.Row() ) : 0.0; } - double GetValue( SCCOL nCol, SCROW nRow ); + double GetValue( SCCOL nCol, SCROW nRow ) const; void GetFormula( SCCOL nCol, SCROW nRow, rtl::OUString& rFormula ); CellType GetCellType( const ScAddress& rPos ) const diff --git a/sc/source/core/data/table2.cxx b/sc/source/core/data/table2.cxx index 73c26baf5f0b..af10a163e73c 100644 --- a/sc/source/core/data/table2.cxx +++ b/sc/source/core/data/table2.cxx @@ -1067,7 +1067,7 @@ void ScTable::GetString( SCCOL nCol, SCROW nRow, rtl::OUString& rString ) } -void ScTable::GetInputString( SCCOL nCol, SCROW nRow, rtl::OUString& rString ) +void ScTable::GetInputString( SCCOL nCol, SCROW nRow, rtl::OUString& rString ) const { if (ValidColRow(nCol,nRow)) aCol[nCol].GetInputString( nRow, rString ); @@ -1076,7 +1076,7 @@ void ScTable::GetInputString( SCCOL nCol, SCROW nRow, rtl::OUString& rString ) } -double ScTable::GetValue( SCCOL nCol, SCROW nRow ) +double ScTable::GetValue( SCCOL nCol, SCROW nRow ) const { if (ValidColRow( nCol, nRow )) return aCol[nCol].GetValue( nRow ); diff --git a/sc/source/core/data/table3.cxx b/sc/source/core/data/table3.cxx index 598a833325bd..a7604dd8ca37 100644 --- a/sc/source/core/data/table3.cxx +++ b/sc/source/core/data/table3.cxx @@ -1081,7 +1081,7 @@ bool isQueryByValue( } std::pair<bool,bool> compareByValue( - ScDocument& rDoc, ScTable& rTab, const ScBaseCell* pCell, SCCOL nCol, SCROW nRow, + const ScDocument& rDoc, const ScTable& rTab, const ScBaseCell* pCell, SCCOL nCol, SCROW nRow, const ScQueryEntry& rEntry, const ScQueryEntry::Item& rItem, bool* pbTestEqualCondition) { bool bOk = false; @@ -1237,7 +1237,7 @@ bool isTestRegExp(const ScQueryParam& rParam, const ScQueryEntry& rEntry, bool* } std::pair<bool,bool> compareByString( - ScDocument& rDoc, ScTable& rTab, ScBaseCell* pCell, SCROW nRow, + const ScDocument& rDoc, const ScTable& rTab, ScBaseCell* pCell, SCROW nRow, const ScQueryParam& rParam, const ScQueryEntry& rEntry, const ScQueryEntry::Item& rItem, bool bMatchWholeCell, ::utl::TransliterationWrapper* pTransliteration, CollatorWrapper* pCollator, bool* pbTestEqualCondition) @@ -1254,7 +1254,7 @@ std::pair<bool,bool> compareByString( if (pCell->GetCellType() != CELLTYPE_NOTE) { sal_uLong nFormat = rTab.GetNumberFormat( static_cast<SCCOL>(rEntry.nField), nRow ); - ScCellFormat::GetInputString( pCell, nFormat, aCellStr, *(rDoc.GetFormatTable()) ); + ScCellFormat::GetInputString(pCell, nFormat, aCellStr, *rDoc.GetFormatTable()); } } else |