The C++ framework for developing highly scalable, high performance servers on Windows platforms.

CEnvironmentBlock Class Reference

Inheritance diagram for CEnvironmentBlock:
Collaboration diagram for CEnvironmentBlock:

List of all members.


Detailed Description

A class for building and manipulating operating system Environment Blocks.


Public Member Functions

 CEnvironmentBlock ()
 CEnvironmentBlock (const Core::StringMap &variables)
 CEnvironmentBlock (const CEnvironmentBlock &rhs)
 ~CEnvironmentBlock () override
CEnvironmentBlockoperator= (const CEnvironmentBlock &rhs)
void LoadProcessEnvironmentStrings ()
const TCHARGetEnvironmentBlock () const override
 Returns an environment block compatible with the format described here.
bool IsUnicodeEnvironment () const override
 Returns true if the environment block returned by GetEnvironmentBlock() is in Unicode.
const Core::StringMapGetStrings () const override
 Returns all of the strings from this environment block as a map of name/value pairs.
void GetStrings (Core::StringMap &variables) const override
 Adds all of the strings from this environment block as name/value pairs to the supplied map of strings. Merges with, and overwrites any existing name/value pairs in the supplied map.
bool IsVariableSet (const Core::_tstring &name) const override
 Returns true if the specified variable is set.
Core::_tstring GetVariable (const Core::_tstring &name) const override
 Returns the value of the specified environment variable or an empty string if the value is not set.
void SetVariable (const Core::_tstring &name, const Core::_tstring &value) override
 Sets the specified environment variable to the supplied value. Note that an empty string for a value is not acceptable; use DeleteEnvironmentVariable to remove a variable.
void DeleteVariable (const Core::_tstring &name) override
 Deletes the specified variable from the environment.
bool TryDeleteVariable (const Core::_tstring &name) override
 Deletes the specified variable from the environment if it exists and returns true, returns false if the variable doesn't exist.


Constructor & Destructor Documentation

CEnvironmentBlock ( const Core::StringMap variables  )  [explicit]

CEnvironmentBlock ( const CEnvironmentBlock rhs  ) 

~CEnvironmentBlock (  )  [override]


Member Function Documentation

CEnvironmentBlock& operator= ( const CEnvironmentBlock rhs  ) 

void LoadProcessEnvironmentStrings (  ) 

const TCHAR * GetEnvironmentBlock (  )  const [override, virtual]

Returns an environment block compatible with the format described here.

Implements IProvideEnvironmentBlock.

bool IsUnicodeEnvironment (  )  const [override, virtual]

Returns true if the environment block returned by GetEnvironmentBlock() is in Unicode.

Implements IProvideEnvironmentBlock.

const StringMap & GetStrings (  )  const [override, virtual]

Returns all of the strings from this environment block as a map of name/value pairs.

Implements IManageEnvironmentVariables.

void GetStrings ( Core::StringMap variables  )  const [override, virtual]

Adds all of the strings from this environment block as name/value pairs to the supplied map of strings. Merges with, and overwrites any existing name/value pairs in the supplied map.

Implements IManageEnvironmentVariables.

bool IsVariableSet ( const Core::_tstring name  )  const [override, virtual]

Returns true if the specified variable is set.

Implements IManageEnvironmentVariables.

Core::_tstring GetVariable ( const Core::_tstring name  )  const [override, virtual]

Returns the value of the specified environment variable or an empty string if the value is not set.

Implements IManageEnvironmentVariables.

void SetVariable ( const Core::_tstring name,
const Core::_tstring value 
) [override, virtual]

Sets the specified environment variable to the supplied value. Note that an empty string for a value is not acceptable; use DeleteEnvironmentVariable to remove a variable.

Implements IManageEnvironmentVariables.

void DeleteVariable ( const Core::_tstring name  )  [override, virtual]

Deletes the specified variable from the environment.

Implements IManageEnvironmentVariables.

bool TryDeleteVariable ( const Core::_tstring name  )  [override, virtual]

Deletes the specified variable from the environment if it exists and returns true, returns false if the variable doesn't exist.

Implements IManageEnvironmentVariables.


Generated on Sun Sep 12 19:11:32 2021 for The Server Framework - v7.4 by doxygen 1.5.3