#include <stdexcept>
#include <type_traits>
#include <vector>
#include <string>
#include <codecvt>
#include <locale>
#include <sstream>
#include <stdlib.h>
#include <string_view>
#include <cmath>
Go to the source code of this file.
|
std::string | agr::multi (const std::string &element, unsigned int n_times) |
| Function used to multiply a string for n times. More...
|
|
std::vector< std::string > | agr::split_string (const std::string &input, const std::string ®ex) |
| Function used to split a string based on a certain reges. More...
|
|
template<typename T_err = std::runtime_error> |
T_err | agr::except_error_func (const std::string &beg="", std::string var=nullptr, const std::string &end="") |
| Function used to throw customized stdexception error. This function is extremely specific to my purposes and you can find examples usages in other my projects lik "osmanip" or "SAFD-algorithm". More...
|
|
template<typename T > |
bool | agr::isFloatingPoint (const T &) |
| Function to check if an expression (not a type) is a floating point or not. I know this function is almost useless, but it has been created for lazy purposes and since it is used in other projects it cannot be eliminated now in order to not break backward compatibility. More...
|
|
template<typename T > |
T | agr::one (const T &iterating_var) |
| Function to find the incremented unit of a loop. Not easy to understand its purpose without context, but it is used to get the loop incremented unit in case of loops with floating-point indexes. See example usage in "osmanip" in progress bars "update" method. More...
|
|
template<class CharT > |
std::conditional_t< std::is_same_v< CharT, char >, const std::basic_string< CharT > &, std::basic_string< CharT > > | agr::StringConverter (const std::string &input_str) |
| Function used to convert an std::string into other string types (std::wstring etc...). If the argument is an std::string it will be returned without any modification. More...
|
|
template<typename T > |
bool | agr::is_escape (const T &str, const ANSI &flag) |
| This method is used to check if an input variable is an ANSI escape sequency or not. More...
|
|
- Author
- Gianluca Bianco (bianc.nosp@m.ogia.nosp@m.nluca.nosp@m.9@gm.nosp@m.ail.c.nosp@m.om)
- Date
- 2022-06-06
- Copyright
- Copyright (c) 2022 Gianluca Bianco under the MIT license.
◆ ARSENALGEAR_UTILS_HPP
#define ARSENALGEAR_UTILS_HPP |