libeditwl
Lightweight C++ library for Nintendo DS(i) formats
Loading...
Searching...
No Matches
twl::fs::StdioFile Class Reference
Inheritance diagram for twl::fs::StdioFile:
twl::fs::File twl::fs::AbstractReaderWriter

Public Member Functions

 StdioFile (const std::string &path)
 
 StdioFile (const StdioFile &)=delete
 
 StdioFile (StdioFile &&)=default
 
Result OpenImpl (const FileMode mode) override
 
Result GetSizeImpl (size_t &out_size) override
 
Result SetOffsetImpl (const size_t offset, const Whence whence) override
 
Result GetOffsetImpl (size_t &out_offset) override
 
Result ReadBufferImpl (void *read_buf, const size_t read_size) override
 
Result WriteBufferImpl (const void *write_buf, const size_t write_size) override
 
Result CloseImpl () override
 
std::string & GetPath ()
 
- Public Member Functions inherited from twl::fs::File
 File (const File &)=delete
 
 File (File &&)=default
 
bool IsOpened ()
 
constexpr bool IsCompressed ()
 
Result OpenRead ()
 
Result OpenWrite (const FileCompression comp=FileCompression::None)
 
Result OpenUpdate ()
 
Result GetSize (size_t &out_size) override
 
Result SetOffset (const ssize_t offset, const Whence whence) override
 
Result GetOffset (size_t &out_offset) override
 
Result ReadBuffer (void *read_buf, const size_t read_size) override
 
Result WriteBuffer (const void *write_buf, const size_t write_size) override
 
Result Close ()
 
- Public Member Functions inherited from twl::fs::AbstractReaderWriter
Result SetAbsoluteOffset (const size_t offset)
 
Result MoveOffset (const ssize_t offset)
 
template<typename T>
Result Read (T &out_t)
 
template<typename T>
Result Write (const T &t)
 
template<typename T>
Result ReadLEB128 (T &out_t)
 
template<typename C>
Result ReadNullTerminatedString (std::basic_string< C > &out_str, const size_t tmp_buf_size=0x200)
 
template<typename C>
Result WriteString (const std::basic_string< C > &str)
 
Result WriteCString (const char *str)
 
Result WriteEnsureAlignmentPadding (const size_t align, size_t &out_pad_size)
 
Result WriteEnsureAlignment (const size_t align)
 
template<typename T>
Result WriteVector (const std::vector< T > &vec)
 
template<typename C>
Result WriteNullTerminatedString (const std::basic_string< C > &str)
 

Additional Inherited Members

- Protected Attributes inherited from twl::fs::File
FileMode mode
 

Member Function Documentation

◆ CloseImpl()

Result twl::fs::StdioFile::CloseImpl ( )
overridevirtual

Implements twl::fs::File.

◆ GetOffsetImpl()

Result twl::fs::StdioFile::GetOffsetImpl ( size_t & out_offset)
overridevirtual

Implements twl::fs::File.

◆ GetSizeImpl()

Result twl::fs::StdioFile::GetSizeImpl ( size_t & out_size)
overridevirtual

Implements twl::fs::File.

◆ OpenImpl()

Result twl::fs::StdioFile::OpenImpl ( const FileMode mode)
overridevirtual

Implements twl::fs::File.

◆ ReadBufferImpl()

Result twl::fs::StdioFile::ReadBufferImpl ( void * read_buf,
const size_t read_size )
overridevirtual

Implements twl::fs::File.

◆ SetOffsetImpl()

Result twl::fs::StdioFile::SetOffsetImpl ( const size_t offset,
const Whence whence )
overridevirtual

Implements twl::fs::File.

◆ WriteBufferImpl()

Result twl::fs::StdioFile::WriteBufferImpl ( const void * write_buf,
const size_t write_size )
overridevirtual

Implements twl::fs::File.


The documentation for this class was generated from the following files: