port from perforce
This commit is contained in:
39
aiwaz/Aiwaz/FileSystem/File.h
Normal file
39
aiwaz/Aiwaz/FileSystem/File.h
Normal file
@@ -0,0 +1,39 @@
|
||||
#pragma once
|
||||
|
||||
#include "IEngine.h"
|
||||
#include "IFileSystem.h"
|
||||
|
||||
|
||||
class File
|
||||
: public IFile
|
||||
{
|
||||
public:
|
||||
File(IEngine* ar_Engine_, char* ac_Buffer_, unsigned int argBufferLength, const string16 argFileName);
|
||||
virtual ~File();
|
||||
|
||||
virtual char* get_Buffer();
|
||||
virtual unsigned int get_BufferLength();
|
||||
virtual void SaveAs(string16 argFileName);
|
||||
|
||||
virtual std::string ReadString();
|
||||
virtual float ReadFloat();
|
||||
virtual int ReadInt();
|
||||
virtual void* ReadDataArray(unsigned int argBytes);
|
||||
|
||||
virtual void RewindFilePointer();
|
||||
virtual char* get_FilePointer() const;
|
||||
virtual void set_FilePointer(char* ac_Position_);
|
||||
virtual bool IsEof() const;
|
||||
|
||||
virtual string16 get_FileName() const { return m_FileName; }
|
||||
|
||||
protected:
|
||||
void CheckIntegrity(unsigned int argBytes);
|
||||
|
||||
private:
|
||||
IEngine* m_Engine;
|
||||
char* m_Buffer;
|
||||
char* m_BufferPosition;
|
||||
unsigned int m_BufferLength;
|
||||
string16 m_FileName;
|
||||
};
|
||||
Reference in New Issue
Block a user