#include <directory.hpp>
Definition at line 55 of file directory.hpp.
Public Member Functions | |
virtual int | compare (const comparable &) const |
Compares two objects. Implementations should check the type of the given object. | |
directory (const directory &) | |
directory (const string &name) | |
directory () | |
const data::list< directory > & | get_dirs () const |
const data::list< file > & | get_files () const |
const gsgl::string & | get_full_path () const |
const gsgl::string & | get_name () const |
directory & | operator= (const directory &) |
~directory () | |
Static Public Member Functions | |
static void | create (const gsgl::string &pathname) |
static bool | exists (const gsgl::string &pathname) |
Returns true if the particular directory exists. | |
Static Public Attributes | |
static const gsgl::string | SEPARATOR |
The system-dependent directory separator. | |
Private Member Functions | |
void | get_paths () |
Private Attributes | |
data::list< directory > | dirs |
data::list< file > | files |
gsgl::string | full_path |
gsgl::string | name |
directory | ( | ) |
Definition at line 64 of file directory.cpp.
References directory::get_paths(), gsgl::io::MAX_PATH_SIZE, and directory::name.
Referenced by directory::get_dirs().
~directory | ( | ) |
Definition at line 86 of file directory.cpp.
int compare | ( | const comparable & | ) | const [virtual] |
Compares two objects. Implementations should check the type of the given object.
Implements comparable.
Definition at line 102 of file directory.cpp.
References string::compare(), and directory::full_path.
void create | ( | const gsgl::string & | pathname | ) | [static] |
Definition at line 207 of file directory.cpp.
References string::c_string(), and string::w_string().
Referenced by application::get_config_overrides().
bool exists | ( | const gsgl::string & | pathname | ) | [static] |
Returns true if the particular directory exists.
Definition at line 201 of file directory.cpp.
References string::c_string().
Referenced by application::get_config_overrides().
const data::list< directory > & get_dirs | ( | ) | const |
Definition at line 173 of file directory.cpp.
References directory::directory(), directory::dirs, directory::full_path, and string::w_string().
const data::list< file > & get_files | ( | ) | const |
Definition at line 147 of file directory.cpp.
References directory::files, directory::full_path, and string::w_string().
const string & get_full_path | ( | ) | const |
Definition at line 141 of file directory.cpp.
References directory::full_path.
Referenced by celestial_body::celestial_body(), application::get_cmdline_dir(), font_impl::get_font_dir(), application::get_program_dir(), application::get_user_dir(), model_part::model_part(), package::package(), star::star(), stellar_db::stellar_db(), and vehicle::vehicle().
const string & get_name | ( | ) | const |
Definition at line 135 of file directory.cpp.
References directory::name.
void get_paths | ( | ) | [private] |
Definition at line 116 of file directory.cpp.
References directory::full_path, gsgl::io::MAX_PATH_SIZE, directory::name, directory::SEPARATOR, and string::w_string().
Referenced by directory::directory(), and directory::operator=().
Definition at line 90 of file directory.cpp.
References directory::dirs, directory::files, directory::get_paths(), and directory::name.
data::list<directory> dirs [mutable, private] |
Definition at line 61 of file directory.hpp.
Referenced by directory::get_dirs(), and directory::operator=().
data::list<file> files [mutable, private] |
Definition at line 60 of file directory.hpp.
Referenced by directory::get_files(), and directory::operator=().
gsgl::string full_path [private] |
Definition at line 58 of file directory.hpp.
Referenced by directory::compare(), directory::get_dirs(), directory::get_files(), directory::get_full_path(), and directory::get_paths().
gsgl::string name [private] |
Definition at line 58 of file directory.hpp.
Referenced by directory::directory(), directory::get_name(), directory::get_paths(), and directory::operator=().
The system-dependent directory separator.
Definition at line 90 of file directory.hpp.
Referenced by file::file(), font_impl::get_font_dir(), directory::get_paths(), and application::get_user_dir().