raccoon::utils namespace

Contents

Functions

auto hexdump(const void* data, size_t size) -> std::string
auto getenv(const std::string& variable, const std::string& default_val) -> std::string
template<class T>
auto hexdump(const std::vector<T>& data) -> std::string
auto hexdump(const std::string& data) -> std::string
auto normalize_url(const std::string& url) -> std::string noexcept

Function documentation

std::string raccoon::utils::hexdump(const void* data, size_t size)

Return a hexdump of some data.

std::string raccoon::utils::getenv(const std::string& variable, const std::string& default_val)

Read an environment variable, with an optional default.

template<class T>
std::string raccoon::utils::hexdump(const std::vector<T>& data)

Return a hexdump of a vector of data.

std::string raccoon::utils::hexdump(const std::string& data)

Return a hexdump of a string.

std::string raccoon::utils::normalize_url(const std::string& url) noexcept

Parameters
url The old url.
Returns std::string The new URL.

Normalize a URL using libcurl.