diff options
Diffstat (limited to 'src/unstable/archivestream.h')
| -rw-r--r-- | src/unstable/archivestream.h | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/src/unstable/archivestream.h b/src/unstable/archivestream.h new file mode 100644 index 0000000..a8ef903 --- /dev/null +++ b/src/unstable/archivestream.h | |||
| @@ -0,0 +1,49 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2007-2014 Xagasoft, All rights reserved. | ||
| 3 | * | ||
| 4 | * This file is part of the libbu++ library and is released under the | ||
| 5 | * terms of the license contained in the file LICENSE. | ||
| 6 | */ | ||
| 7 | #ifndef BU_ARCHIVE_STREAM_H | ||
| 8 | #define BU_ARCHIVE_STREAM_H | ||
| 9 | |||
| 10 | #include "bu/archivebase.h" | ||
| 11 | #include "bu/stream.h" | ||
| 12 | |||
| 13 | namespace Bu | ||
| 14 | { | ||
| 15 | class ArchiveStream : public Stream | ||
| 16 | { | ||
| 17 | public: | ||
| 18 | ArchiveStream( Bu::ArchiveBase &ar ); | ||
| 19 | virtual ~ArchiveStream(); | ||
| 20 | |||
| 21 | virtual void close(); | ||
| 22 | virtual size read( void *pBuf, size iBytes ); | ||
| 23 | virtual size write( const void *pBuf, size iBytes ); | ||
| 24 | virtual size tell(); | ||
| 25 | virtual void seek( size offset ); | ||
| 26 | virtual void setPos( size pos ); | ||
| 27 | virtual void setPosEnd( size pos ); | ||
| 28 | virtual bool isEos(); | ||
| 29 | virtual bool isOpen(); | ||
| 30 | virtual void flush(); | ||
| 31 | virtual bool canRead(); | ||
| 32 | virtual bool canWrite(); | ||
| 33 | virtual bool isReadable(); | ||
| 34 | virtual bool isWritable(); | ||
| 35 | virtual bool isSeekable(); | ||
| 36 | virtual bool isBlocking(); | ||
| 37 | virtual void setBlocking( bool bBlocking=true ); | ||
| 38 | virtual void setSize( size iSize ); | ||
| 39 | virtual size getSize() const; | ||
| 40 | virtual size getBlockSize() const; | ||
| 41 | virtual Bu::String getLocation() const; | ||
| 42 | |||
| 43 | private: | ||
| 44 | Bu::ArchiveBase &ar; | ||
| 45 | size iPos; | ||
| 46 | }; | ||
| 47 | } | ||
| 48 | |||
| 49 | #endif | ||
