24 : m_opaque_up(
clone(rhs.m_opaque_up)) {
79 m_opaque_up->insert_or_assign(name, std::string(value));
82 return m_opaque_up->try_emplace(name, std::string(value)).second;
104 auto split = llvm::StringRef(name_and_value).split(
'=');
105 m_opaque_up->insert_or_assign(split.first.str(), split.second.str());
113 for (
size_t i = 0; i < entries.
GetSize(); i++) {
#define LLDB_INSTRUMENT_VA(...)
const char * GetValueAtIndex(size_t index)
Return the value of the environment variable at a given index from the internal list of environment v...
void PutEntry(const char *name_and_value)
Add or replace an existing environment variable.
bool Set(const char *name, const char *value, bool overwrite)
Set the value of a given environment variable.
void Clear()
Delete all the environment variables.
SBStringList GetEntries()
Return all environment variables contained in this object.
const char * GetNameAtIndex(size_t index)
Return the name of the environment variable at a given index from the internal list of environment va...
bool Unset(const char *name)
Unset an environment variable if exists.
lldb_private::Environment & ref() const
std::unique_ptr< lldb_private::Environment > m_opaque_up
const lldb::SBEnvironment & operator=(const lldb::SBEnvironment &rhs)
const char * Get(const char *name)
Return the value of a given environment variable.
void SetEntries(const SBStringList &entries, bool append)
Update this object with the given environment variables.
void AppendString(const char *str)
const char * GetStringAtIndex(size_t idx)
A uniqued constant string class.
const char * AsCString(const char *value_if_empty=nullptr) const
Get the string value as a C string.
static std::string compose(const value_type &KeyValue)
A class that represents a running process on the host machine.
std::unique_ptr< T > clone(const std::unique_ptr< T > &src)