Skip to content

christian-schilling/stringtools

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

#stringtools

Helpers for common string manipulation tasks in C++.

##Usage

#include <stringtools/all.hpp>
using namespace str;

std::string text = format("hello %s")("world");
std::vector<std::string> v = split(", ")("hello, world");
std::string hw = join(" ")(v);

print("abc:",1,2,3);
// abc: 1 2 3

std::map<std::pair<std::string,bool>,std::vector<int>> m{
    {{"one",true},{1}},
    {{"two",0},{1,2}}
};
print(m);
// {("one",true): [1], ("two",false): [1, 2]}

About

A small C++ wrapper arround snprintf, to make it useable in an expression

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors