Pyrogenesis  trunk
Public Member Functions | Static Private Member Functions | Private Attributes | List of all members
Paths Class Reference

Wrapper class for OS paths used by the game. More...

#include <Paths.h>

Collaboration diagram for Paths:
Collaboration graph
[legend]

Public Member Functions

 Paths (const CmdLineArgs &args)
 
const OsPathRoot () const
 Returns the game's root directory. More...
 
const OsPathRData () const
 Returns directory for read-only data installed with the game. More...
 
const OsPathGameData () const
 Returns directory for game-managed data and mods. More...
 
const OsPathUserData () const
 Returns directory for user-created data Only things created in response to an explicit user action should go here. More...
 
const OsPathConfig () const
 Returns config file directory. More...
 
const OsPathCache () const
 Returns cache directory. More...
 
const OsPathLogs () const
 Returns logs directory. More...
 

Static Private Member Functions

static OsPath Root (const OsPath &argv0)
 
static OsPath RootData (const OsPath &argv0)
 
static OsPath XDG_Path (const char *envname, const OsPath &home, const OsPath &defaultPath)
 

Private Attributes

OsPath m_root
 
OsPath m_rdata
 
OsPath m_gameData
 
OsPath m_userData
 
OsPath m_config
 
OsPath m_cache
 
OsPath m_logs
 

Detailed Description

Wrapper class for OS paths used by the game.

Constructor & Destructor Documentation

◆ Paths()

Paths::Paths ( const CmdLineArgs args)

Member Function Documentation

◆ Cache()

const OsPath& Paths::Cache ( ) const
inline

Returns cache directory.

◆ Config()

const OsPath& Paths::Config ( ) const
inline

Returns config file directory.

◆ GameData()

const OsPath& Paths::GameData ( ) const
inline

Returns directory for game-managed data and mods.

◆ Logs()

const OsPath& Paths::Logs ( ) const
inline

Returns logs directory.

◆ RData()

const OsPath& Paths::RData ( ) const
inline

Returns directory for read-only data installed with the game.

◆ Root() [1/2]

const OsPath& Paths::Root ( ) const
inline

Returns the game's root directory.

◆ Root() [2/2]

OsPath Paths::Root ( const OsPath argv0)
staticprivate

◆ RootData()

OsPath Paths::RootData ( const OsPath argv0)
staticprivate

◆ UserData()

const OsPath& Paths::UserData ( ) const
inline

Returns directory for user-created data Only things created in response to an explicit user action should go here.

(note: only Windows currently treats this differently than GameData)

◆ XDG_Path()

OsPath Paths::XDG_Path ( const char *  envname,
const OsPath home,
const OsPath defaultPath 
)
staticprivate

Member Data Documentation

◆ m_cache

OsPath Paths::m_cache
private

◆ m_config

OsPath Paths::m_config
private

◆ m_gameData

OsPath Paths::m_gameData
private

◆ m_logs

OsPath Paths::m_logs
private

◆ m_rdata

OsPath Paths::m_rdata
private

◆ m_root

OsPath Paths::m_root
private

◆ m_userData

OsPath Paths::m_userData
private

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