Stg::FileManager Class Reference

#include <file_manager.hh>

List of all members.

Public Member Functions

 FileManager ()
void newWorld (const std::string worldfile)
 Update the worldfile path.
const std::string worldsRoot () const
 Return the path where the current worldfile was loaded from.

Static Public Member Functions

static std::string findFile (const std::string filename)
static bool readable (const std::string path)
 Determine whether a file can be opened for reading.
static std::string stagePath ()
 Return the STAGEPATH environment variable.

Constructor & Destructor Documentation

Stg::FileManager::FileManager (  ) 

Member Function Documentation

std::string Stg::FileManager::findFile ( const std::string  filename  )  [static]

Search for a file in the current directory, in the prefix/share/stage location, and in the locations specified by the STAGEPATH environment variable. Returns the first match or the original filename if not found.

void Stg::FileManager::newWorld ( const std::string  worldfile  )  [inline]

Update the worldfile path.

bool Stg::FileManager::readable ( const std::string  path  )  [static]

Determine whether a file can be opened for reading.

std::string Stg::FileManager::stagePath (  )  [static]

Return the STAGEPATH environment variable.

const std::string Stg::FileManager::worldsRoot (  )  const [inline]

Return the path where the current worldfile was loaded from.


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

Generated on Tue Oct 20 15:42:06 2009 for Stage by  doxygen 1.6.1