From 7c6c9538b03c9eae24e38fbeb30dd76a16aff1d2 Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Thu, 20 Jan 2011 05:30:43 +0000 Subject: Wow, got the Stream changes propegated, all tests build with string instead of fstring, and updated the copyright notice to extend to 2011 --- src/queuebuf.h | 26 +++++++++++++++----------- 1 file changed, 15 insertions(+), 11 deletions(-) (limited to 'src/queuebuf.h') diff --git a/src/queuebuf.h b/src/queuebuf.h index 395c6ba..84b50e1 100644 --- a/src/queuebuf.h +++ b/src/queuebuf.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Xagasoft, All rights reserved. + * Copyright (C) 2007-2011 Xagasoft, All rights reserved. * * This file is part of the libbu++ library and is released under the * terms of the license contained in the file LICENSE. @@ -27,14 +27,14 @@ namespace Bu int getSize(); virtual void close(); - virtual size_t read( void *pBuf, size_t nBytes ); - virtual size_t peek( void *pBuf, size_t nBytes ); - virtual size_t peek( void *pBuf, size_t nBytes, size_t nSkip ); - virtual size_t write( const void *pBuf, size_t nBytes ); - virtual long tell(); - virtual void seek( long offset ); - virtual void setPos( long pos ); - virtual void setPosEnd( long pos ); + virtual Bu::size read( void *pBuf, Bu::size nBytes ); + virtual Bu::size peek( void *pBuf, Bu::size nBytes ); + virtual Bu::size peek( void *pBuf, Bu::size nBytes, Bu::size nSkip ); + virtual Bu::size write( const void *pBuf, Bu::size nBytes ); + virtual Bu::size tell(); + virtual void seek( Bu::size offset ); + virtual void setPos( Bu::size pos ); + virtual void setPosEnd( Bu::size pos ); virtual bool isEos(); virtual bool isOpen(); virtual void flush(); @@ -45,7 +45,11 @@ namespace Bu virtual bool isSeekable(); virtual bool isBlocking(); virtual void setBlocking( bool bBlocking=true ); - virtual void setSize( long iSize ); + virtual void setSize( Bu::size iSize ); + + virtual size getSize() const; + virtual size getBlockSize() const; + virtual Bu::String getLocation() const; private: void addBlock(); @@ -55,7 +59,7 @@ namespace Bu int iBlockSize; int iReadOffset; int iWriteOffset; - size_t iTotalSize; + Bu::size iTotalSize; typedef Bu::List BlockList; BlockList lBlocks; }; -- cgit v1.2.3