[Box Backup-commit] COMMIT r3123 - box/trunk/lib/common

subversion at boxbackup.org subversion at boxbackup.org
Mon Oct 22 21:48:54 BST 2012


Author: chris
Date: 2012-10-22 21:48:54 +0100 (Mon, 22 Oct 2012)
New Revision: 3123

Modified:
   box/trunk/lib/common/MemBlockStream.h
Log:
Add helper methods to get read-only access to the buffer, and its size,
wrapped by a MemBlockStream.


Modified: box/trunk/lib/common/MemBlockStream.h
===================================================================
--- box/trunk/lib/common/MemBlockStream.h	2012-10-22 20:47:58 UTC (rev 3122)
+++ box/trunk/lib/common/MemBlockStream.h	2012-10-22 20:48:54 UTC (rev 3123)
@@ -41,6 +41,8 @@
 	virtual void Seek(pos_type Offset, int SeekType);
 	virtual bool StreamDataLeft();
 	virtual bool StreamClosed();
+	virtual const void* GetBuffer() const { return mpBuffer; }
+	virtual int GetSize() const { return mBytesInBuffer; }
 
 private:
 	const char *mpBuffer;




More information about the Boxbackup-commit mailing list