From b44cbb26efe1d0b0950b1e1613e131b506dc3876 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Tue, 20 Jan 2015 12:38:10 +0200 Subject: new loplugin: change virtual methods to non-virtual Where we can prove that the virtual method is never overriden. In the case of pure-virtual methods, we remove the method entirely. Sometimes this leads to entire methods and fields being eliminated. Change-Id: I138ef81c95f115dbd8c023a83cfc7e9d5d6d14ae --- include/store/store.hxx | 36 ------------------------------------ 1 file changed, 36 deletions(-) (limited to 'include/store') diff --git a/include/store/store.hxx b/include/store/store.hxx index 1d9b74c44a9b..85c546564e47 100644 --- a/include/store/store.hxx +++ b/include/store/store.hxx @@ -316,42 +316,6 @@ public: return store_findNext (m_hImpl, &it); } - /** Directory traversal helper. - @see travel() - */ - class traveller - { - public: - /** Directory traversal callback. - @param it [in] current directory entry. - @return sal_True to continue iteration, sal_False to stop. - */ - virtual bool visit (const iterator& it) = 0; - - protected: - ~traveller() {} - }; - - /** Directory traversal. - @see store_findFirst() - @see store_findNext() - - @param rTraveller [in] the traversal callback. - @return store_E_NoMoreFiles upon end of iteration. - */ - inline storeError travel (traveller & rTraveller) const - { - storeError eErrCode = store_E_InvalidHandle; - if (m_hImpl) - { - iterator it; - eErrCode = store_findFirst (m_hImpl, &it); - while ((eErrCode == store_E_None) && rTraveller.visit(it)) - eErrCode = store_findNext (m_hImpl, &it); - } - return eErrCode; - } - private: /** Representation. */ -- cgit