Declaration of utilities for std types.
Definition in file stdtypesutils.hpp.
#include <medusa/Config.hpp>
#include <medusa/bits/utils/assert.hpp>
#include <string>
#include <vector>
#include <tuple>
#include <type_traits>
Go to the source code of this file.
Classes | |
struct | mm::tuple_index< T, Tuple > |
Returns the first index of type T in Tuple . More... | |
struct | mm::tuple_index< T, std::tuple< T, Types... > > |
Succesful match. More... | |
struct | mm::tuple_index< T, std::tuple< U, Types... > > |
Unsuccessful match and recursive search. More... | |
struct | mm::tuple_has_type< T, Tuple > |
Find type T in Tuple – declaration. More... | |
struct | mm::tuple_has_type< T, std::tuple<> > |
Find type T in Tuple – failed case. More... | |
struct | mm::tuple_has_type< T, std::tuple< U, Ts... > > |
Find type T in Tuple – unsuccessful, continue searching. More... | |
struct | mm::tuple_has_type< T, std::tuple< T, Ts... > > |
Find type T in Tuple – success. More... | |
Namespaces | |
mm | |
Root namespace for the whole library. | |
Functions | |
std::vector< std::string > | mm::split (const std::string &s, const std::string &delim) |
Splits string by delim , returning a vector of tokens (including empty). More... | |
std::vector< std::string > | mm::split (const std::string &s, char delim) |
Overload for char . More... | |
std::string | mm::join (const std::vector< std::string > &parts, const std::string &joiner) |
Joins a vector of strings back together. More... | |
std::string | mm::join (const std::vector< std::string > &parts, char joiner) |
Overload for char . More... | |
template<typename container_t > | |
container_t & | mm::sort (container_t &v) |
Sorts a container inplace. More... | |
template<typename container_t , typename predicate_t > | |
container_t & | mm::sort (container_t &v, const predicate_t &pred) |
Sorts a container inplace according to ordering defined by pred . More... | |
template<typename container_t > | |
container_t | mm::sorted (container_t v) |
Returns a sorted copy of container. More... | |
template<typename container_t , typename predicate_t > | |
container_t | mm::sorted (container_t v, const predicate_t &pred) |
Returns a sorted copy of container ordered according to pred . More... | |
template<typename container_t , typename T > | |
container_t | mm::pad (container_t container, T value) |
Pads a ragged array with given value. More... | |