diff options
Diffstat (limited to 'CPP/7zip/Common/OffsetStream.h')
-rw-r--r-- | CPP/7zip/Common/OffsetStream.h | 22 |
1 files changed, 9 insertions, 13 deletions
diff --git a/CPP/7zip/Common/OffsetStream.h b/CPP/7zip/Common/OffsetStream.h index 9074a24..9bd554c 100644 --- a/CPP/7zip/Common/OffsetStream.h +++ b/CPP/7zip/Common/OffsetStream.h | |||
@@ -1,26 +1,22 @@ | |||
1 | // OffsetStream.h | 1 | // OffsetStream.h |
2 | 2 | ||
3 | #ifndef __OFFSET_STREAM_H | 3 | #ifndef ZIP7_INC_OFFSET_STREAM_H |
4 | #define __OFFSET_STREAM_H | 4 | #define ZIP7_INC_OFFSET_STREAM_H |
5 | 5 | ||
6 | #include "../../Common/MyCom.h" | 6 | #include "../../Common/MyCom.h" |
7 | 7 | ||
8 | #include "../IStream.h" | 8 | #include "../IStream.h" |
9 | 9 | ||
10 | class COffsetOutStream: | 10 | Z7_CLASS_IMP_NOQIB_1( |
11 | public IOutStream, | 11 | COffsetOutStream |
12 | public CMyUnknownImp | 12 | , IOutStream |
13 | { | 13 | ) |
14 | UInt64 _offset; | 14 | Z7_IFACE_COM7_IMP(ISequentialOutStream) |
15 | |||
15 | CMyComPtr<IOutStream> _stream; | 16 | CMyComPtr<IOutStream> _stream; |
17 | UInt64 _offset; | ||
16 | public: | 18 | public: |
17 | HRESULT Init(IOutStream *stream, UInt64 offset); | 19 | HRESULT Init(IOutStream *stream, UInt64 offset); |
18 | |||
19 | MY_UNKNOWN_IMP | ||
20 | |||
21 | STDMETHOD(Write)(const void *data, UInt32 size, UInt32 *processedSize); | ||
22 | STDMETHOD(Seek)(Int64 offset, UInt32 seekOrigin, UInt64 *newPosition); | ||
23 | STDMETHOD(SetSize)(UInt64 newSize); | ||
24 | }; | 20 | }; |
25 | 21 | ||
26 | #endif | 22 | #endif |