37 inline typename std::enable_if<T == task_id, uint64_t>::type
env_prop()
44 envName =
"DDS_TASK_ID";
49 const char* env = std::getenv(envName.c_str());
55 ret = std::stoul(env);
74 inline typename std::enable_if<T == task_index || T == collection_index, size_t>::type
env_prop()
81 envName =
"DDS_TASK_INDEX";
84 envName =
"DDS_COLLECTION_INDEX";
89 const char* env = std::getenv(envName.c_str());
113 template <EEnvProp T>
123 envName =
"DDS_TASK_NAME";
126 envName =
"DDS_COLLECTION_NAME";
129 envName =
"DDS_GROUP_NAME";
132 envName =
"DDS_LOCATION";
135 envName =
"DDS_TASK_PATH";
140 const char* env = std::getenv(envName.c_str());
144 return std::string(env);
associated with $DDS_COLLECTION_NAME - ID of the parent collection.
Definition: dds_env_prop.h:23
associated with $DDS_TASK_PATH - full path to the user task, for example, main/group1/collection_12/t...
Definition: dds_env_prop.h:20
std::enable_if< T==task_id, uint64_t >::type env_prop()
The function returns a value for a given environment property.
Definition: dds_env_prop.h:37
Definition: dds-agent/src/AgentConnectionManager.h:16
associated with $DDS_TASK_ID environment variable.
Definition: dds_env_prop.h:17
associated with $DDS_GROUP_NAME - ID of the parent group.
Definition: dds_env_prop.h:24
EEnvProp
a list of envioronment properties
Definition: dds_env_prop.h:15
associated with $DDS_TASK_NAME - ID of the task.
Definition: dds_env_prop.h:19
associated with $DDS_TASK_INDEX environment variable.
Definition: dds_env_prop.h:18
associated with $DDS_COLLECTION_INDEX environemnt variable.
Definition: dds_env_prop.h:22
associated with $DDS_LOCATION environemnt variable.
Definition: dds_env_prop.h:25