summaryrefslogtreecommitdiff
path: root/src/configpaths.cpp
blob: 3fac407dbed9591b3d33c0a6ff5a49cd44cd8be4 (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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
#include "configpaths.h"

namespace newsboat {

ConfigPaths::ConfigPaths()
	: rs_object(configpaths::bridged::create())
{
}

bool ConfigPaths::initialized() const
{
	return newsboat::configpaths::bridged::initialized(*rs_object);
}

std::string ConfigPaths::error_message() const
{
	return std::string(newsboat::configpaths::bridged::error_message(*rs_object));
}

void ConfigPaths::process_args(const CliArgsParser& args)
{
	newsboat::configpaths::bridged::process_args(*rs_object, args.get_rust_ref());
}

bool ConfigPaths::try_migrate_from_newsbeuter()
{
	return newsboat::configpaths::bridged::try_migrate_from_newsbeuter(*rs_object);
}

bool ConfigPaths::create_dirs() const
{
	return newsboat::configpaths::bridged::create_dirs(*rs_object);
}

void ConfigPaths::set_cache_file(const std::string& new_cachefile)
{
	newsboat::configpaths::bridged::set_cache_file(*rs_object, new_cachefile);
}

std::string ConfigPaths::url_file() const
{
	return std::string(newsboat::configpaths::bridged::url_file(*rs_object));
}

std::string ConfigPaths::cache_file() const
{
	return std::string(newsboat::configpaths::bridged::cache_file(*rs_object));
}

std::string ConfigPaths::config_file() const
{
	return std::string(newsboat::configpaths::bridged::config_file(*rs_object));
}

std::string ConfigPaths::lock_file() const
{
	return std::string(newsboat::configpaths::bridged::lock_file(*rs_object));
}

std::string ConfigPaths::queue_file() const
{
	return std::string(newsboat::configpaths::bridged::queue_file(*rs_object));
}

std::string ConfigPaths::search_history_file() const
{
	return std::string(newsboat::configpaths::bridged::search_history_file(*rs_object));
}

std::string ConfigPaths::cmdline_history_file() const
{
	return std::string(newsboat::configpaths::bridged::cmdline_history_file(*rs_object));
}

} // namespace newsboat