filters

MSWrite::MemoryDevice Class Reference

#include <libmswrite_defs.h>

Inheritance diagram for MSWrite::MemoryDevice:
MSWrite::Device

Public Member Functions

bool read (Byte *, const DWord)
bool write (const Byte *, const DWord)
bool seek (const long, const int)
long tell (void)
Public Member Functions inherited from MSWrite::Device
bool setCache (Byte *const cache)
bool readInternal (Byte *buf, const long numBytes)
bool writeInternal (const Byte *buf, const long numBytes)
bool seekInternal (const long offset, const int whence)
long tellInternal (void) const
void debug (const char *s, const int i)
void debug (const char *s1, const char *s2)
void debug (const char *s1, const Byte *s2)
bool good (void) const
int bad (void) const
virtual void debug (const char *s)
virtual void debug (const int i)
virtual void error (const int errorCode, const char *message, const char *file="", const int lineno=0, DWord token=NoToken)

Additional Inherited Members

Static Public Attributes inherited from MSWrite::Device
static const DWord NoToken = DWord (0xABCD1234)
Protected Attributes inherited from MSWrite::Device
int m_error

Detailed Description

Device capable only of reading/writing to memory blocks (used internally by LibMSWrite).

Definition at line 434 of file libmswrite_defs.h.

Constructor & Destructor Documentation

◆ MemoryDevice()

MSWrite::MemoryDevice::MemoryDevice ( )
inline

Definition at line 437 of file libmswrite_defs.h.

◆ ~MemoryDevice()

virtual MSWrite::MemoryDevice::~MemoryDevice ( )
inlinevirtual

Definition at line 441 of file libmswrite_defs.h.

Member Function Documentation

◆ read()

bool MSWrite::MemoryDevice::read ( Byte * buf,
const DWord numBytes )
inlinevirtual

Functions that the user must implement.

If the seek function is called to move past EOF (when writing), pad from EOF to the new location with 0's and then seek.

It is your responsibility to call error() if a file op fails.

Implements MSWrite::Device.

Definition at line 445 of file libmswrite_defs.h.

◆ seek()

bool MSWrite::MemoryDevice::seek ( const long ,
const int  )
inlinevirtual

Implements MSWrite::Device.

Definition at line 455 of file libmswrite_defs.h.

◆ tell()

long MSWrite::MemoryDevice::tell ( void )
inlinevirtual

Implements MSWrite::Device.

Definition at line 460 of file libmswrite_defs.h.

◆ write()

bool MSWrite::MemoryDevice::write ( const Byte * ,
const DWord  )
inlinevirtual

Implements MSWrite::Device.

Definition at line 450 of file libmswrite_defs.h.


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