summaryrefslogtreecommitdiff
path: root/include/tools/stream.hxx
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-01-20 12:38:10 +0200
committerNoel Grandin <noel@peralex.com>2015-01-26 08:42:28 +0200
commitb44cbb26efe1d0b0950b1e1613e131b506dc3876 (patch)
tree9b4d5d99e5dad0971079b997a02a6d96536709ca /include/tools/stream.hxx
parent26ad60aec69310fecd918f1c2e09056aa4782320 (diff)
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
Diffstat (limited to 'include/tools/stream.hxx')
-rw-r--r--include/tools/stream.hxx14
1 files changed, 7 insertions, 7 deletions
diff --git a/include/tools/stream.hxx b/include/tools/stream.hxx
index 59561de1d9c2..27854e05c051 100644
--- a/include/tools/stream.hxx
+++ b/include/tools/stream.hxx
@@ -127,10 +127,10 @@ public:
virtual ~SvLockBytes() { close(); }
- virtual const SvStream * GetStream() const { return m_pStream; }
+ const SvStream * GetStream() const { return m_pStream; }
virtual void SetSynchronMode(bool bTheSync = true) { m_bSync = bTheSync; }
- virtual bool IsSynchronMode() const { return m_bSync; }
+ bool IsSynchronMode() const { return m_bSync; }
virtual ErrCode ReadAt(sal_uInt64 nPos, void * pBuffer, sal_Size nCount,
sal_Size * pRead) const;
@@ -462,10 +462,10 @@ public:
friend SvStream& operator<<( SvStream& rStr, SvStrPtr f ); // for Manips
/// end of input seen during previous i/o operation
- virtual bool eof() const { return bIsEof; }
+ bool eof() const { return bIsEof; }
/// stream is broken
- virtual bool bad() const { return GetError() != 0; }
+ bool bad() const { return GetError() != 0; }
/** Get state
@@ -698,7 +698,7 @@ protected:
/// AllocateMemory must update pBuf accordingly
/// - pBuf: Address of new block
- virtual bool AllocateMemory( sal_Size nSize );
+ bool AllocateMemory( sal_Size nSize );
/// ReAllocateMemory must update the following variables:
/// - pBuf: Address of new block
@@ -706,11 +706,11 @@ protected:
/// Set to 0 , if new block size is 0 bytes
/// - nSize: New block size
/// - nPos: Set to 0 if position outside of block
- virtual bool ReAllocateMemory( long nDiff );
+ bool ReAllocateMemory( long nDiff );
/// Is called when this stream allocated the buffer or the buffer is
/// resized. FreeMemory may need to NULLify handles in derived classes.
- virtual void FreeMemory();
+ void FreeMemory();
SvMemoryStream(void*) { } // for sub-classes