blob: 070341d437eed54dfa1cdc3783bbb06fbe6dd7a6 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
#ifndef NEWSBEUTER_FORMATSTRING__H
#define NEWSBEUTER_FORMATSTRING__H
#include <map>
#include <string>
namespace newsbeuter {
class fmtstr_formatter {
public:
fmtstr_formatter() { }
void register_fmt(char f, const std::string& value);
std::string do_format(const std::string& fmt, unsigned int width = 0);
std::wstring do_wformat(const std::wstring& fmt, unsigned int width = 0);
private:
std::map<char, std::wstring> fmts;
};
}
#endif
|