se_core::FileManager Class Reference

File system base class. More...

#include <FileManager.hpp>

List of all members.

Public Member Functions

 FileManager ()
virtual ~FileManager ()
virtual void init (const char **files)
virtual void cleanup ()
virtual bool addFileIfExists (const char *filename)=0
virtual InputStreamopen (const char *filename)=0
virtual void close (InputStream *&is)=0
virtual OutputStreamopenOutput (const char *filename)=0
virtual void closeOutput (OutputStream *&is)=0
void load (const char *filename)
void save (const char *filename)
virtual bool exists (const char *filename) const =0
void loadDirectory (const char *directory)
 Load and parse all the files in this directory and all subdirectories.
void loadBatch (const char *batchFilename)
 Load and parse all the files in the batch file.
virtual int fileCount () const =0
virtual const char * filename (int index) const =0


Detailed Description

File system base class.

This class should be subclassed in a platform dependent layer. This enables SagaEngine's data file architecture to both handle real file systems, network transfers, and file system emulation on ROMs.

See also:
TextInputStream

BinaryInputStream

Definition at line 38 of file FileManager.hpp.


Constructor & Destructor Documentation

se_core::FileManager::FileManager  ) 
 

Definition at line 34 of file FileManager.cpp.

se_core::FileManager::~FileManager  )  [virtual]
 

Definition at line 39 of file FileManager.cpp.


Member Function Documentation

virtual bool se_core::FileManager::addFileIfExists const char *  filename  )  [pure virtual]
 

virtual void se_core::FileManager::cleanup  )  [inline, virtual]
 

Definition at line 43 of file FileManager.hpp.

virtual void se_core::FileManager::close InputStream *&  is  )  [pure virtual]
 

virtual void se_core::FileManager::closeOutput OutputStream *&  is  )  [pure virtual]
 

virtual bool se_core::FileManager::exists const char *  filename  )  const [pure virtual]
 

virtual int se_core::FileManager::fileCount  )  const [pure virtual]
 

virtual const char* se_core::FileManager::filename int  index  )  const [pure virtual]
 

virtual void se_core::FileManager::init const char **  files  )  [inline, virtual]
 

Definition at line 42 of file FileManager.hpp.

void se_core::FileManager::load const char *  filename  ) 
 

Definition at line 44 of file FileManager.cpp.

References AssertWarning, se_core::ParseManager::parse(), and se_core::IoSchema::parser().

void se_core::FileManager::loadBatch const char *  batchFilename  ) 
 

Load and parse all the files in the batch file.

The batch should contain one filename per line.

Definition at line 80 of file FileManager.cpp.

References AssertWarning, LogDetail, LogFatal, se_core::ParseManager::parse(), se_core::IoSchema::parser(), and se_core::InputStream::readLine().

void se_core::FileManager::loadDirectory const char *  directory  ) 
 

Load and parse all the files in this directory and all subdirectories.

Definition at line 63 of file FileManager.cpp.

References AssertWarning, se_core::ParseManager::parse(), and se_core::IoSchema::parser().

virtual InputStream* se_core::FileManager::open const char *  filename  )  [pure virtual]
 

virtual OutputStream* se_core::FileManager::openOutput const char *  filename  )  [pure virtual]
 

void se_core::FileManager::save const char *  filename  ) 
 

Definition at line 54 of file FileManager.cpp.

References se_core::EncodeManager::encode(), and se_core::IoSchema::encoder().


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

Home Page | SagaEngine trunk (updated nightly) reference generated Sun Dec 2 20:06:25 2007 by Doxygen version 1.3.9.1.

SourceForge.net Logo