mirror of
https://github.com/AxioDL/PrimeWorldEditor.git
synced 2025-09-01 08:18:51 +00:00
36 lines
957 B
C++
36 lines
957 B
C++
#ifndef CFILEOUTSTREAM_H
|
|
#define CFILEOUTSTREAM_H
|
|
|
|
#include "IOutputStream.h"
|
|
#include "IOUtil.h"
|
|
|
|
class CFileOutStream : public IOutputStream
|
|
{
|
|
private:
|
|
FILE *mpFStream;
|
|
std::string mName;
|
|
unsigned long mSize;
|
|
|
|
public:
|
|
CFileOutStream();
|
|
CFileOutStream(const std::string& rkFile);
|
|
CFileOutStream(const std::string& rkFile, IOUtil::EEndianness FileEndianness);
|
|
CFileOutStream(const CFileOutStream& rkSrc);
|
|
~CFileOutStream();
|
|
void Open(const std::string& rkFile, IOUtil::EEndianness);
|
|
void Update(const std::string& rkFile, IOUtil::EEndianness FileEndianness);
|
|
void Close();
|
|
|
|
void WriteBytes(const void *pkSrc, unsigned long Count);
|
|
bool Seek(long Offset, long Origin);
|
|
bool Seek64(long long Offset, long Origin);
|
|
long Tell() const;
|
|
long long Tell64() const;
|
|
bool EoF() const;
|
|
bool IsValid() const;
|
|
long Size() const;
|
|
std::string FileName() const;
|
|
};
|
|
|
|
#endif // CFILEOUTSTREAM_H
|