Main Page   Namespace List   Class Hierarchy   Compound List   File List   Compound Members   File Members  

CL_InputSource_Memory Class Reference

also: CL_InputSourceProvider - Interface to open input sources with. More...

#include <inputsource_memory.h>

Inheritance diagram for CL_InputSource_Memory:

Inheritance graph
[legend]
Collaboration diagram for CL_InputSource_Memory:

Collaboration graph
[legend]
List of all members.

Public Methods

 CL_InputSource_Memory (std::string data)
virtual ~CL_InputSource_Memory ()
virtual void set_system_mode ()
virtual void set_big_endian_mode ()
virtual void set_little_endian_mode ()
virtual int read_int32 ()
virtual unsigned int read_uint32 ()
 retval: The integer read.

virtual short read_short16 ()
 retval: The unsigned integer read.

virtual unsigned short read_ushort16 ()
 retval: The short read.

virtual char read_char8 ()
 retval: The unsigned short read.

virtual unsigned char read_uchar8 ()
 retval: The char read.

virtual float read_float32 ()
 retval: The unsigned char read.

virtual bool read_bool ()
 retval: The float read.

virtual int read (void *data, int size)
 retval: The bool read.

virtual void open ()
 param: data - Points to an array where the read data is stored.param: size - Number of bytes to read.retval: Num bytes actually read.

virtual void close ()
virtual CL_InputSourceclone () const
virtual int tell () const
 retval: The clone of the input source.

virtual void seek (int pos, SeekEnum seek_type)
 retval: Current position in input source.

virtual int size () const
 param: pos - Position relative to 'seek_type'.param: seek_type - Defines what the 'pos' is relative to. Can be either seek_set, seek_cur og seek_end.

virtual std::string read_string ()
 retval: Size of the input source.

virtual void push_position ()
 retval: The string read.

virtual void pop_position ()
std::string get_data ()

Private Attributes

std::string m_data
unsigned int m_pos
bool m_delete_data

Detailed Description

also: CL_InputSourceProvider - Interface to open input sources with.

Definition at line 22 of file inputsource_memory.h.


Constructor & Destructor Documentation

CL_InputSource_Memory::CL_InputSource_Memory ( std::string data )
 

virtual CL_InputSource_Memory::~CL_InputSource_Memory ( ) [virtual]
 


Member Function Documentation

virtual CL_InputSource* CL_InputSource_Memory::clone ( ) const [virtual]
 

Reimplemented from CL_InputSource.

virtual void CL_InputSource_Memory::close ( ) [virtual]
 

Reimplemented from CL_InputSource.

std::string CL_InputSource_Memory::get_data ( ) [inline]
 

Definition at line 111 of file inputsource_memory.h.

void CL_InputSource_Memory::open ( ) [virtual]
 

param: data - Points to an array where the read data is stored.param: size - Number of bytes to read.retval: Num bytes actually read.

Reimplemented from CL_InputSource.

virtual void CL_InputSource_Memory::pop_position ( ) [virtual]
 

Reimplemented from CL_InputSource.

virtual void CL_InputSource_Memory::push_position ( ) [virtual]
 

retval: The string read.

Reimplemented from CL_InputSource.

int CL_InputSource_Memory::read ( void * data,
int size ) [virtual]
 

retval: The bool read.

Reimplemented from CL_InputSource.

bool CL_InputSource_Memory::read_bool ( ) [virtual]
 

retval: The float read.

char CL_InputSource_Memory::read_char8 ( ) [virtual]
 

retval: The unsigned short read.

Reimplemented from CL_InputSource.

float CL_InputSource_Memory::read_float32 ( ) [virtual]
 

retval: The unsigned char read.

Reimplemented from CL_InputSource.

virtual int CL_InputSource_Memory::read_int32 ( ) [virtual]
 

Reimplemented from CL_InputSource.

short CL_InputSource_Memory::read_short16 ( ) [virtual]
 

retval: The unsigned integer read.

Reimplemented from CL_InputSource.

std::string CL_InputSource_Memory::read_string ( ) [virtual]
 

retval: Size of the input source.

Reimplemented from CL_InputSource.

unsigned char CL_InputSource_Memory::read_uchar8 ( ) [virtual]
 

retval: The char read.

Reimplemented from CL_InputSource.

unsigned int CL_InputSource_Memory::read_uint32 ( ) [virtual]
 

retval: The integer read.

Reimplemented from CL_InputSource.

unsigned short CL_InputSource_Memory::read_ushort16 ( ) [virtual]
 

retval: The short read.

Reimplemented from CL_InputSource.

void CL_InputSource_Memory::seek ( int pos,
SeekEnum seek_type ) [virtual]
 

retval: Current position in input source.

Reimplemented from CL_InputSource.

virtual void CL_InputSource_Memory::set_big_endian_mode ( ) [virtual]
 

Reimplemented from CL_InputSource.

virtual void CL_InputSource_Memory::set_little_endian_mode ( ) [virtual]
 

Reimplemented from CL_InputSource.

virtual void CL_InputSource_Memory::set_system_mode ( ) [virtual]
 

Reimplemented from CL_InputSource.

int CL_InputSource_Memory::size ( ) const [virtual]
 

param: pos - Position relative to 'seek_type'.param: seek_type - Defines what the 'pos' is relative to. Can be either seek_set, seek_cur og seek_end.

Reimplemented from CL_InputSource.

int CL_InputSource_Memory::tell ( ) const [virtual]
 

retval: The clone of the input source.

Reimplemented from CL_InputSource.


Member Data Documentation

std::string CL_InputSource_Memory::m_data [private]
 

Definition at line 115 of file inputsource_memory.h.

bool CL_InputSource_Memory::m_delete_data [private]
 

Definition at line 117 of file inputsource_memory.h.

unsigned int CL_InputSource_Memory::m_pos [private]
 

Definition at line 116 of file inputsource_memory.h.


The documentation for this class was generated from the following file:
Generated at Wed Apr 4 19:57:04 2001 for ClanLib by doxygen1.2.6 written by Dimitri van Heesch, © 1997-2001