2006-06-15 04:19:30 +00:00
|
|
|
#ifndef _VOLUMESTREAM_H_
|
|
|
|
#define _VOLUMESTREAM_H_
|
|
|
|
|
|
|
|
#include <windows.h>
|
|
|
|
#include "Stream.h"
|
|
|
|
|
|
|
|
namespace Framework
|
|
|
|
{
|
|
|
|
namespace Win32
|
|
|
|
{
|
|
|
|
class CVolumeStream : public CStream
|
|
|
|
{
|
|
|
|
public:
|
2018-04-30 20:01:23 +00:00
|
|
|
CVolumeStream(char);
|
|
|
|
virtual ~CVolumeStream();
|
|
|
|
virtual void Seek(int64, STREAM_SEEK_DIRECTION);
|
|
|
|
virtual uint64 Tell();
|
|
|
|
virtual uint64 Read(void*, uint64);
|
|
|
|
virtual uint64 Write(const void*, uint64);
|
|
|
|
virtual bool IsEOF();
|
2006-06-15 04:19:30 +00:00
|
|
|
|
|
|
|
private:
|
2018-04-30 20:01:23 +00:00
|
|
|
void SyncCache();
|
2006-06-15 04:19:30 +00:00
|
|
|
|
2018-04-30 20:01:23 +00:00
|
|
|
HANDLE m_nVolume;
|
|
|
|
void* m_pCache;
|
|
|
|
uint64 m_nCacheSector;
|
2006-06-15 04:19:30 +00:00
|
|
|
|
2018-04-30 20:01:23 +00:00
|
|
|
uint64 m_nPosition;
|
|
|
|
uint64 m_nSectorSize;
|
2006-06-15 04:19:30 +00:00
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|