Lines Matching refs:variable_name
29 bool GetVar(StringPiece variable_name, std::string* result) override { in GetVar() argument
30 if (GetVarImpl(variable_name, result)) in GetVar()
37 char first_char = variable_name[0]; in GetVar()
40 alternate_case_var = ToUpperASCII(variable_name); in GetVar()
42 alternate_case_var = ToLowerASCII(variable_name); in GetVar()
48 bool SetVar(StringPiece variable_name, in SetVar() argument
50 return SetVarImpl(variable_name, new_value); in SetVar()
53 bool UnSetVar(StringPiece variable_name) override { in UnSetVar() argument
54 return UnSetVarImpl(variable_name); in UnSetVar()
58 bool GetVarImpl(StringPiece variable_name, std::string* result) { in GetVarImpl() argument
61 ::GetEnvironmentVariable(UTF8ToWide(variable_name).c_str(), nullptr, 0); in GetVarImpl()
66 ::GetEnvironmentVariable(UTF8ToWide(variable_name).c_str(), value.get(), in GetVarImpl()
72 const char* env_value = getenv(variable_name.data()); in GetVarImpl()
82 bool SetVarImpl(StringPiece variable_name, const std::string& new_value) { in SetVarImpl() argument
85 return !!SetEnvironmentVariable(UTF8ToWide(variable_name).c_str(), in SetVarImpl()
89 return !setenv(variable_name.data(), new_value.c_str(), 1); in SetVarImpl()
93 bool UnSetVarImpl(StringPiece variable_name) { in UnSetVarImpl() argument
96 return !!SetEnvironmentVariable(UTF8ToWide(variable_name).c_str(), nullptr); in UnSetVarImpl()
99 return !unsetenv(variable_name.data()); in UnSetVarImpl()
140 bool Environment::HasVar(StringPiece variable_name) { in HasVar() argument
141 return GetVar(variable_name, nullptr); in HasVar()