1 #ifndef OSMIUM_UTIL_CONFIG_HPP 2 #define OSMIUM_UTIL_CONFIG_HPP 43 # define strcasecmp _stricmp 51 const char* env = getenv(
"OSMIUM_POOL_THREADS");
53 return std::atoi(env);
59 const char* env = getenv(
"OSMIUM_USE_POOL_THREADS_FOR_PBF_PARSING");
61 if (!strcasecmp(env,
"off") ||
62 !strcasecmp(env,
"false") ||
63 !strcasecmp(env,
"no") ||
64 !strcasecmp(env,
"0")) {
71 inline std::size_t
get_max_queue_size(
const char* queue_name, std::size_t default_value) noexcept {
73 std::string name{
"OSMIUM_MAX_"};
75 name +=
"_QUEUE_SIZE";
76 const char* env = getenv(name.c_str());
78 auto value = std::atoi(env);
79 return value == 0 ? default_value : value;
88 #endif // OSMIUM_UTIL_CONFIG_HPP std::size_t get_max_queue_size(const char *queue_name, std::size_t default_value) noexcept
Definition: config.hpp:71
bool use_pool_threads_for_pbf_parsing() noexcept
Definition: config.hpp:58
int get_pool_threads() noexcept
Definition: config.hpp:50
Namespace for everything in the Osmium library.
Definition: assembler.hpp:53