xtd 1.0.0
Loading...
Searching...
No Matches
env.hpp
Go to the documentation of this file.
1
4#pragma once
5#include "environment.hpp"
6
8namespace xtd {
9
26 [[nodiscard]] inline auto env(const xtd::string& variable) -> xtd::string {return xtd::environment::get_environment_variable(variable);}
44 [[nodiscard]] inline auto env(const xtd::string& variable, xtd::environment_variable_target target) -> xtd::string {return xtd::environment::get_environment_variable(variable, target);}
45}
46
66#define env_(...) xtd::env(__VA_ARGS__)
static auto get_environment_variable(const xtd::string &variable) -> xtd::string
Retrieves the value of an environment variable from the current process.
Contains xtd::environment class.
xtd::basic_string< char > string
Represents text as a sequence of UTF-8 code units.
Definition __string_definitions.hpp:43
environment_variable_target
Specifies the location where an environment variable is stored or retrieved in a set or get operation...
Definition environment_variable_target.hpp:15
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition abstract_object.hpp:8