Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members  

ExecutionEnvironment Class Reference

#include <executionEnvironment.h>

List of all members.

Static Public Member Functions

INLINE bool has_environment_variable (const string &var)
INLINE string get_environment_variable (const string &var)
INLINE void set_environment_variable (const string &var, const string &value)
string expand_string (const string &str)
INLINE int get_num_args ()
INLINE string get_arg (int n)
INLINE string get_binary_name ()
Filename get_cwd ()

Private Types

typedef map< string, string > EnvironmentVariables
typedef vector_string CommandArguments

Private Member Functions

 ExecutionEnvironment ()
bool ns_has_environment_variable (const string &var) const
string ns_get_environment_variable (const string &var) const
void ns_set_environment_variable (const string &var, const string &value)
int ns_get_num_args () const
string ns_get_arg (int n) const
string ns_get_binary_name () const
void read_environment_variables ()
void read_args ()

Static Private Member Functions

ExecutionEnvironment * get_ptr ()

Private Attributes

EnvironmentVariables _variables
CommandArguments _args
string _binary_name

Static Private Attributes

ExecutionEnvironment * _global_ptr = NULL


Member Typedef Documentation

typedef vector_string ExecutionEnvironment::CommandArguments [private]
 

Definition at line 74 of file executionEnvironment.h.

typedef map<string, string> ExecutionEnvironment::EnvironmentVariables [private]
 

Definition at line 71 of file executionEnvironment.h.


Constructor & Destructor Documentation

ExecutionEnvironment::ExecutionEnvironment  )  [private]
 

Definition at line 64 of file executionEnvironment.cxx.

References read_args(), and read_environment_variables().


Member Function Documentation

string ExecutionEnvironment::expand_string const string &  str  )  [static]
 

Definition at line 80 of file executionEnvironment.cxx.

References end, get_environment_variable(), size_t, and start.

Referenced by Filename::expand_from().

INLINE string ExecutionEnvironment::get_arg int  n  )  [static]
 

Referenced by Config::ConfigTable::ParseArgs().

INLINE string ExecutionEnvironment::get_binary_name  )  [static]
 

Referenced by Config::Config< GetConfig >::Defined(), Config::Config< GetConfig >::Get(), Config::Config< GetConfig >::GetAll(), and Config::ConfigTable::GetData().

Filename ExecutionEnvironment::get_cwd  )  [static]
 

Definition at line 134 of file executionEnvironment.cxx.

References assert, buffer, Filename::from_os_specific(), NULL, and size_t.

Referenced by Filename::make_absolute(), and Filename::make_canonical().

INLINE string ExecutionEnvironment::get_environment_variable const string &  var  )  [static]
 

Referenced by expand_string(), Config::ConfigTable::Get(), Config::ConfigTable::GetData(), Config::ConfigTable::MicroConfig(), and Config::ConfigTable::ReadConfigFile().

INLINE int ExecutionEnvironment::get_num_args  )  [static]
 

Referenced by Config::ConfigTable::ParseArgs().

ExecutionEnvironment * ExecutionEnvironment::get_ptr  )  [static, private]
 

Definition at line 264 of file executionEnvironment.cxx.

References _global_ptr, and NULL.

INLINE bool ExecutionEnvironment::has_environment_variable const string &  var  )  [static]
 

Referenced by Config::ConfigTable::Defined(), Config::ConfigTable::Get(), Config::ConfigTable::GetData(), and Config::ConfigTable::ReadConfigFile().

string ExecutionEnvironment::ns_get_arg int  n  )  const [private]
 

Definition at line 237 of file executionEnvironment.cxx.

References _args, assert, n, and ns_get_num_args().

string ExecutionEnvironment::ns_get_binary_name  )  const [private]
 

Definition at line 250 of file executionEnvironment.cxx.

References _binary_name.

string ExecutionEnvironment::ns_get_environment_variable const string &  var  )  const [private]
 

Definition at line 181 of file executionEnvironment.cxx.

References _variables, getenv(), and NULL.

int ExecutionEnvironment::ns_get_num_args  )  const [private]
 

Definition at line 223 of file executionEnvironment.cxx.

References _args.

Referenced by ns_get_arg().

bool ExecutionEnvironment::ns_has_environment_variable const string &  var  )  const [private]
 

Definition at line 165 of file executionEnvironment.cxx.

References _variables, getenv(), and NULL.

void ExecutionEnvironment::ns_set_environment_variable const string &  var,
const string &  value
[private]
 

Definition at line 205 of file executionEnvironment.cxx.

References _variables, and malloc().

void ExecutionEnvironment::read_args  )  [private]
 

Definition at line 330 of file executionEnvironment.cxx.

References _args, _binary_name, and index.

Referenced by ExecutionEnvironment().

void ExecutionEnvironment::read_environment_variables  )  [private]
 

Definition at line 280 of file executionEnvironment.cxx.

References _variables, and variable.

Referenced by ExecutionEnvironment().

INLINE void ExecutionEnvironment::set_environment_variable const string &  var,
const string &  value
[static]
 


Member Data Documentation

CommandArguments ExecutionEnvironment::_args [private]
 

Definition at line 75 of file executionEnvironment.h.

Referenced by ns_get_arg(), ns_get_num_args(), and read_args().

string ExecutionEnvironment::_binary_name [private]
 

Definition at line 77 of file executionEnvironment.h.

Referenced by ns_get_binary_name(), and read_args().

ExecutionEnvironment * ExecutionEnvironment::_global_ptr = NULL [static, private]
 

Definition at line 54 of file executionEnvironment.cxx.

Referenced by get_ptr().

EnvironmentVariables ExecutionEnvironment::_variables [private]
 

Definition at line 72 of file executionEnvironment.h.

Referenced by ns_get_environment_variable(), ns_has_environment_variable(), ns_set_environment_variable(), and read_environment_variables().


The documentation for this class was generated from the following files:
Generated on Fri Apr 18 01:34:55 2003 for DTool by doxygen1.3