Game Accessibility Library logo SourceForge.net Logo
Game Accessibility Suite: CATStreamFile Class Reference

CATStreamFile Class Reference
[Common Accessibility Technology [CAT] library]

#include <CATStreamFile.h>

Inheritance diagram for CATStreamFile:

CATStream

List of all members.


Detailed Description

Generic file stream class based on STDIO.

CATStreamFile provides a basic file stream interface. It does NOT currently support locking (non-shared) modes, and will assert or return an error if you try to use them.

File sharing is a platform dependant issue. Create a platform dependant class inherited from CATStream if you need to control it. Alternatively, implement lock files or named semaphores in this class. I don't need it yet.

Definition at line 33 of file CATStreamFile.h.


Public Member Functions

 CATStreamFile ()
virtual ~CATStreamFile ()
virtual CATResult Open (const CATWChar *pathname, OPEN_MODE mode)
virtual CATResult Close ()
virtual bool IsOpen ()
virtual CATResult Read (void *buffer, CATUInt32 &length)
virtual CATResult Write (const void *buffer, CATUInt32 length)
virtual CATResult Size (CATInt64 &filesize)
virtual bool IsSeekable ()
 IsSeekable() returns true for files.
virtual CATResult SeekRelative (CATInt32 offset)
virtual CATResult SeekAbsolute (CATInt64 position)
virtual CATResult SeekFromEnd (CATInt32 offset)
virtual CATResult GetPosition (CATInt64 &position)
virtual CATString GetName () const
 GetName() retrieves the filename of the stream.
virtual CATResult ReadAbs (void *buffer, CATUInt32 &length, CATInt64 position)
virtual CATResult WriteAbs (const void *buffer, CATUInt32 length, CATInt64 position)

Protected Attributes

CATString fFilename

Private Member Functions

CATStreamFileoperator= (const CATStreamFile &srcStream)

Private Attributes

FILE * fFileHandle
 STDIO file handle.

The documentation for this class was generated from the following files:
Generated on Mon Feb 11 04:10:56 2008 for Game Accessibility Suite by doxygen 1.5.4