CFileSystem Class Reference

#include <CFileSystem.h>

Inheritance diagram for CFileSystem:

IFileSystem IrrUnknown

Detailed Description

FileSystem which uses normal files and one zipfile

Public Member Functions

Protected Member Functions


Constructor & Destructor Documentation

CFileSystem (  ) 

~CFileSystem (  )  [virtual]


Member Function Documentation

bool addFolderFileArchive ( const c8 filename,
bool  ignoreCase = true,
bool  ignorePaths = true 
) [virtual]

Useful for handling data which will be in a zip file

Parameters:
filename,: Filename of the unzipped zip archive base directory to add to the file system.
ignoreCase,: If set to true, files in the archive can be accessed without writing all letters in the right case.
ignorePaths,: If set to true, files in the added archive can be accessed without its complete path.
Returns:
Returns true if the archive was added successful, false if not.

Implements IFileSystem.

bool addPakFileArchive ( const c8 filename,
bool  ignoreCase = true,
bool  ignorePaths = true 
) [virtual]

Implements IFileSystem.

bool addZipFileArchive ( const c8 filename,
bool  ignoreCase = true,
bool  ignorePaths = true 
) [virtual]

Implements IFileSystem.

bool changeWorkingDirectoryTo ( const c8 newDirectory  )  [virtual]

Changes the current Working Directory to the string given. The string is operating system dependent. Under Windows it will look like this: "drive:\directory\sudirectory\"

Implements IFileSystem.

IReadFile * createAndOpenFile ( const c8 filename  )  [virtual]

Implements IFileSystem.

IWriteFile * createAndWriteFile ( const c8 filename,
bool  append = false 
) [virtual]

Implements IFileSystem.

IAttributes * createEmptyAttributes ( video::IVideoDriver driver  )  [virtual]

Implements IFileSystem.

IFileList * createFileList (  )  [virtual]

Creates a list of files and directories in the current working directory and returns it.

Implements IFileSystem.

IReadFile * createMemoryReadFile ( void *  memory,
s32  len,
const c8 fileName,
bool  deleteMemoryWhenDropped = false 
) [virtual]

Implements IFileSystem.

IXMLReader * createXMLReader ( IReadFile file  )  [virtual]

Implements IFileSystem.

IXMLReader * createXMLReader ( const c8 filename  )  [virtual]

Implements IFileSystem.

IXMLReaderUTF8 * createXMLReaderUTF8 ( IReadFile file  )  [virtual]

Implements IFileSystem.

IXMLReaderUTF8 * createXMLReaderUTF8 ( const c8 filename  )  [virtual]

Implements IFileSystem.

IXMLWriter * createXMLWriter ( IWriteFile file  )  [virtual]

Implements IFileSystem.

IXMLWriter * createXMLWriter ( const c8 filename  )  [virtual]

Implements IFileSystem.

bool drop (  )  [inline, inherited]

Drops the object. Decrements the reference counter by one. Returns true, if the object was deleted. The IrrUnknown class provides a basic reference counting mechanism with its methods grab() and drop(). Most objects of the Irrlicht Engine are derived from IrrUnknown, and so they are reference counted.

When you create an object in the Irrlicht engine, calling a method which starts with 'create', an object is created, and you get a pointer to the new object. If you no longer need the object, you have to call drop(). This will destroy the object, if grab() was not called in another part of you program, because this part still needs the object. Note, that you only need to call drop() to the object, if you created it, and the method had a 'create' in it.

A simple example:

If you want to create a texture, you may want to call an imaginable method IDriver::createTexture. You call ITexture* texture = driver->createTexture(dimension2d<s32>(128, 128)); If you no longer need the texture, call texture->drop(). If you want to load a texture, you may want to call imaginable method IDriver::loadTexture. You do this like ITexture* texture = driver->loadTexture("example.jpg"); You will not have to drop the pointer to the loaded texture, because the name of the method does not start with 'create'. The texture is stored somewhere by the driver.

bool existFile ( const c8 filename  )  [virtual]

Implements IFileSystem.

irr::core::stringc getAbsolutePath ( irr::core::stringc filename  )  [virtual]

Implements IFileSystem.

const c8* getDebugName (  )  const [inline, inherited]

Returns the debug name of the object. The Debugname may only be set and changed by the object itself. This method should only be used in Debug mode.

Returns:
Returns a string, previously set by setDebugName();

const c8 * getWorkingDirectory (  )  [virtual]

Implements IFileSystem.

void grab (  )  [inline, inherited]

Grabs the object. Increments the reference counter by one. Someone who calls grab() to an object, should later also call drop() to it. If an object never gets as much drop() as grab() calls, it will never be destroyed. The IrrUnknown class provides a basic reference counting mechanism with its methods grab() and drop(). Most objects of the Irrlicht Engine are derived from IrrUnknown, and so they are reference counted.

When you create an object in the Irrlicht engine, calling a method which starts with 'create', an object is created, and you get a pointer to the new object. If you no longer need the object, you have to call drop(). This will destroy the object, if grab() was not called in another part of you program, because this part still needs the object. Note, that you only need to call drop() to the object, if you created it, and the method had a 'create' in it.

A simple example:

If you want to create a texture, you may want to call an imaginable method IDriver::createTexture. You call ITexture* texture = driver->createTexture(dimension2d<s32>(128, 128)); If you no longer need the texture, call texture->drop(). If you want to load a texture, you may want to call imaginable method IDriver::loadTexture. You do this like ITexture* texture = driver->loadTexture("example.jpg"); You will not have to drop the pointer to the loaded texture, because the name of the method does not start with 'create'. The texture is stored somewhere by the driver.

void setDebugName ( const c8 newName  )  [inline, protected, inherited]

Sets the debug name of the object. The Debugname may only be set and changed by the object itself. This method should only be used in Debug mode.

Parameters:
newName,: New debug name to set.


Generated on Fri Apr 27 14:47:14 2007 for IrrSpintz by  doxygen 1.5.1-p1