blob: c44338d8a254ddda68a84a40311a55f3015593bf (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
#ifndef NEWSBOAT_FORMATSTRING_H_
#define NEWSBOAT_FORMATSTRING_H_
#include "libnewsboat-ffi/src/fmtstrformatter.rs.h"
#include <string>
namespace newsboat {
class FmtStrFormatter {
public:
FmtStrFormatter();
FmtStrFormatter(FmtStrFormatter&&) = default;
FmtStrFormatter& operator=(FmtStrFormatter&&) = default;
~FmtStrFormatter() = default;
void register_fmt(char f, const std::string& value);
std::string do_format(const std::string& fmt, unsigned int width = 0);
private:
rust::Box<fmtstrformatter::bridged::FmtStrFormatter> rs_object;
};
} // namespace newsboat
#endif /* NEWSBOAT_FORMATSTRING_H_ */
|