libyui  3.4.2
YEnvVar Class Reference

Helper class to represent an environment variable and its value. More...

#include <YEnvVar.h>

Public Member Functions

 YEnvVar (const std::string &name=std::string())
 Constructor: Retrieve the environment variable 'name' and store the value (unless 'name' is empty).
 
std::string name () const
 Return the name of the environment variable.
 
bool isSet () const
 Return 'true' if the environment variable is set.
 
std::string value () const
 Return the value of the environment variable.
 
bool isEqual (const std::string &str, bool caseSensitive=false) const
 Return 'true' if the environment variable is set and the value is 'str'.
 
bool operator== (const std::string &str) const
 Case-insensitive comparison (shortcut for isEqual() ): Return 'true' if the environment variable is set and the value is 'str'.
 
bool contains (const std::string &str, bool caseSensitive=false) const
 Return 'true' if the environment variable is set and the value contains 'str'.
 

Detailed Description

Helper class to represent an environment variable and its value.

Definition at line 36 of file YEnvVar.h.


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