Teuchos - Trilinos Tools Package
Version of the Day
Toggle main menu visibility
Loading...
Searching...
No Matches
core
src
Teuchos_EnvVariables.hpp
1
// @HEADER
2
// *****************************************************************************
3
// Teuchos: Common Tools Package
4
//
5
// Copyright 2004 NTESS and the Teuchos contributors.
6
// SPDX-License-Identifier: BSD-3-Clause
7
// *****************************************************************************
8
// @HEADER
9
10
#ifndef TEUCHOS_ENVVARIABLES_HPP
11
#define TEUCHOS_ENVVARIABLES_HPP
12
13
#include <string_view>
14
15
namespace
Teuchos
{
16
17
template
<
typename
T>
18
T getEnvironmentVariable(
const
std::string_view environmentVariableName,
19
const
T defaultValue);
20
21
bool
idempotentlyGetNamedEnvironmentVariableAsBool(
22
const
char
name[],
bool
&initialized,
const
char
environmentVariableName[],
23
const
bool
defaultValue);
24
36
template
<
typename
T>
37
T
idempotentlyGetEnvironmentVariable
(
38
T &value,
bool
&initialized,
const
std::string_view environmentVariableName,
39
const
T defaultValue);
40
41
}
// namespace Teuchos
42
43
#endif
Teuchos
The Teuchos namespace contains all of the classes, structs and enums used by Teuchos,...
Teuchos::idempotentlyGetEnvironmentVariable
T idempotentlyGetEnvironmentVariable(T &value, bool &initialized, const std::string_view environmentVariableName, const T defaultValue)
Read a variable from the environment. Example usage:
Definition
Teuchos_EnvVariables.cpp:182
Generated by
1.17.0