summaryrefslogtreecommitdiff
path: root/store
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-10-19 11:09:13 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-10-20 08:50:48 +0200
commit14d45665433eec974acd96f813f2bf314bdb3eba (patch)
tree814e8fc8448754fa32ad447095a4353ab4dfb7d1 /store
parent8f8a1e301c7f5b9e924e192ab68b7baa23dcc47a (diff)
loplugin:constmethod in codemaker,registry,store
Change-Id: Ie75875974f054ff79bd64b1c261e79e2b78eb7fc Reviewed-on: https://gerrit.libreoffice.org/43540 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'store')
-rw-r--r--store/source/storbios.cxx8
-rw-r--r--store/source/storbios.hxx8
-rw-r--r--store/source/stordata.cxx8
-rw-r--r--store/source/stordata.hxx10
-rw-r--r--store/source/stortree.cxx4
-rw-r--r--store/source/stortree.hxx4
6 files changed, 21 insertions, 21 deletions
diff --git a/store/source/storbios.cxx b/store/source/storbios.cxx
index 12208b1c597a..bf343abd290e 100644
--- a/store/source/storbios.cxx
+++ b/store/source/storbios.cxx
@@ -688,7 +688,7 @@ void OStorePageBIOS::cleanup_Impl()
* Low Level: Precond: initialized, exclusive access.
*/
storeError OStorePageBIOS::read (
- sal_uInt32 nAddr, void *pData, sal_uInt32 nSize)
+ sal_uInt32 nAddr, void *pData, sal_uInt32 nSize) const
{
// Check precond.
if (!m_xLockBytes.is())
@@ -703,7 +703,7 @@ storeError OStorePageBIOS::read (
* Low Level: Precond: initialized, writeable, exclusive access.
*/
storeError OStorePageBIOS::write (
- sal_uInt32 nAddr, const void *pData, sal_uInt32 nSize)
+ sal_uInt32 nAddr, const void *pData, sal_uInt32 nSize) const
{
// Check precond.
if (!m_xLockBytes.is())
@@ -874,7 +874,7 @@ storeError OStorePageBIOS::loadObjectAt (OStorePageObject & rPage, sal_uInt32 nA
* loadObjectAt_Impl.
* Internal: Precond: initialized, readable, exclusive access.
*/
-storeError OStorePageBIOS::loadObjectAt_Impl (OStorePageObject & rPage, sal_uInt32 nAddr)
+storeError OStorePageBIOS::loadObjectAt_Impl (OStorePageObject & rPage, sal_uInt32 nAddr) const
{
storeError eErrCode = m_xCache->lookupPageAt (rPage.get(), nAddr);
if (eErrCode != store_E_NotExists)
@@ -920,7 +920,7 @@ storeError OStorePageBIOS::saveObjectAt (OStorePageObject & rPage, sal_uInt32 nA
* saveObjectAt_Impl.
* Internal: Precond: initialized, writeable, exclusive access.
*/
-storeError OStorePageBIOS::saveObjectAt_Impl (OStorePageObject & rPage, sal_uInt32 nAddr)
+storeError OStorePageBIOS::saveObjectAt_Impl (OStorePageObject & rPage, sal_uInt32 nAddr) const
{
// Guard page (incl. set location).
storeError eErrCode = rPage.guard (nAddr);
diff --git a/store/source/storbios.hxx b/store/source/storbios.hxx
index 997cfbc9471b..f223b4d0d258 100644
--- a/store/source/storbios.hxx
+++ b/store/source/storbios.hxx
@@ -65,12 +65,12 @@ public:
/** read.
*/
storeError read (
- sal_uInt32 nAddr, void *pData, sal_uInt32 nSize);
+ sal_uInt32 nAddr, void *pData, sal_uInt32 nSize) const;
/** write.
*/
storeError write (
- sal_uInt32 nAddr, const void *pData, sal_uInt32 nSize);
+ sal_uInt32 nAddr, const void *pData, sal_uInt32 nSize) const;
/** isWriteable.
*/
@@ -163,9 +163,9 @@ private:
/** Page Maintenance.
*/
storeError loadObjectAt_Impl (
- OStorePageObject & rPage, sal_uInt32 nAddr);
+ OStorePageObject & rPage, sal_uInt32 nAddr) const;
storeError saveObjectAt_Impl (
- OStorePageObject & rPage, sal_uInt32 nAddr);
+ OStorePageObject & rPage, sal_uInt32 nAddr) const;
OStorePageBIOS (const OStorePageBIOS&) = delete;
OStorePageBIOS& operator= (const OStorePageBIOS&) = delete;
diff --git a/store/source/stordata.cxx b/store/source/stordata.cxx
index a2c992b983d6..1127674f8097 100644
--- a/store/source/stordata.cxx
+++ b/store/source/stordata.cxx
@@ -211,7 +211,7 @@ storeError OStoreIndirectionPageObject::verify (sal_uInt32 nAddr) const
storeError OStoreIndirectionPageObject::read (
sal_uInt16 nSingle,
OStoreDataPageObject &rData,
- OStorePageBIOS &rBIOS)
+ OStorePageBIOS &rBIOS) const
{
PageHolderObject< page > xImpl (m_xPage);
page const & rPage = (*xImpl);
@@ -237,7 +237,7 @@ storeError OStoreIndirectionPageObject::read (
sal_uInt16 nDouble,
sal_uInt16 nSingle,
OStoreDataPageObject &rData,
- OStorePageBIOS &rBIOS)
+ OStorePageBIOS &rBIOS) const
{
PageHolderObject< page > xImpl (m_xPage);
page const & rPage = (*xImpl);
@@ -270,7 +270,7 @@ storeError OStoreIndirectionPageObject::read (
sal_uInt16 nDouble,
sal_uInt16 nSingle,
OStoreDataPageObject &rData,
- OStorePageBIOS &rBIOS)
+ OStorePageBIOS &rBIOS) const
{
PageHolderObject< page > xImpl (m_xPage);
page const & rPage = (*xImpl);
@@ -723,7 +723,7 @@ OStoreDirectoryPageObject::scope (
storeError OStoreDirectoryPageObject::read (
sal_uInt32 nPage,
OStoreDataPageObject &rData,
- OStorePageBIOS &rBIOS)
+ OStorePageBIOS &rBIOS) const
{
// Determine scope and link indices.
page::DataBlock::LinkDescriptor aLink;
diff --git a/store/source/stordata.hxx b/store/source/stordata.hxx
index c8f1597f551a..5014971da3da 100644
--- a/store/source/stordata.hxx
+++ b/store/source/stordata.hxx
@@ -80,7 +80,7 @@ struct OStoreDataPageData : public store::PageData
/** guard (external representation).
*/
- void guard() { (void) this; /* loplugin:staticmethods */ }
+ void guard() const { (void) this; /* loplugin:staticmethods */ }
/** verify (external representation).
*/
@@ -216,20 +216,20 @@ public:
storeError read (
sal_uInt16 nSingle,
OStoreDataPageObject &rData,
- OStorePageBIOS &rBIOS);
+ OStorePageBIOS &rBIOS) const;
storeError read (
sal_uInt16 nDouble,
sal_uInt16 nSingle,
OStoreDataPageObject &rData,
- OStorePageBIOS &rBIOS);
+ OStorePageBIOS &rBIOS) const;
storeError read (
sal_uInt16 nTriple,
sal_uInt16 nDouble,
sal_uInt16 nSingle,
OStoreDataPageObject &rData,
- OStorePageBIOS &rBIOS);
+ OStorePageBIOS &rBIOS) const;
/** write (indirect data page).
*/
@@ -707,7 +707,7 @@ public:
storeError read (
sal_uInt32 nPage,
OStoreDataPageObject &rData,
- OStorePageBIOS &rBIOS);
+ OStorePageBIOS &rBIOS) const;
/** write (external data page).
*/
diff --git a/store/source/stortree.cxx b/store/source/stortree.cxx
index 30264e0917b6..624945914f75 100644
--- a/store/source/stortree.cxx
+++ b/store/source/stortree.cxx
@@ -301,7 +301,7 @@ storeError OStoreBTreeNodeObject::remove (
* testInvariant.
* Precond: root node page loaded.
*/
-void OStoreBTreeRootObject::testInvariant (char const * message)
+void OStoreBTreeRootObject::testInvariant (char const * message) const
{
OSL_PRECOND(m_xPage.get() != nullptr, "OStoreBTreeRootObject::testInvariant(): Null pointer");
SAL_WARN_IF( (m_xPage->location() - m_xPage->size()) != 0, "store", message);
@@ -380,7 +380,7 @@ storeError OStoreBTreeRootObject::find_lookup (
OStoreBTreeNodeObject & rNode, // [out]
sal_uInt16 & rIndex, // [out]
OStorePageKey const & rKey,
- OStorePageBIOS & rBIOS)
+ OStorePageBIOS & rBIOS) const
{
// Init node w/ root page.
testInvariant("OStoreBTreeRootObject::find_lookup(): enter");
diff --git a/store/source/stortree.hxx b/store/source/stortree.hxx
index 872ff0821432..f70aad057f9f 100644
--- a/store/source/stortree.hxx
+++ b/store/source/stortree.hxx
@@ -256,7 +256,7 @@ public:
OStoreBTreeNodeObject & rNode, // [out]
sal_uInt16 & rIndex, // [out]
OStorePageKey const & rKey,
- OStorePageBIOS & rBIOS);
+ OStorePageBIOS & rBIOS) const;
/** find_insert (possibly with split()).
* Precond: root node page loaded.
@@ -271,7 +271,7 @@ private:
/** testInvariant.
* Precond: root node page loaded.
*/
- void testInvariant (char const * message);
+ void testInvariant (char const * message) const;
/** change (Root).
*