summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibCore/ConfigFile.h
diff options
context:
space:
mode:
authornetworkException <git@nwex.de>2021-08-19 22:28:45 +0200
committerAndreas Kling <kling@serenityos.org>2021-08-22 01:32:25 +0200
commit54bbe52b5143954dcdb700207de43343e5102ab8 (patch)
tree3a010bb2ec5e6fe1c88ee2eb15855f2fcbd78f21 /Userland/Libraries/LibCore/ConfigFile.h
parent2ea2d026c22460e70ac16afd4fa7d928093bb098 (diff)
downloadserenity-54bbe52b5143954dcdb700207de43343e5102ab8.zip
LibCore: Convert ConfigFile to east const
Diffstat (limited to 'Userland/Libraries/LibCore/ConfigFile.h')
-rw-r--r--Userland/Libraries/LibCore/ConfigFile.h24
1 files changed, 12 insertions, 12 deletions
diff --git a/Userland/Libraries/LibCore/ConfigFile.h b/Userland/Libraries/LibCore/ConfigFile.h
index bfce1c95ad..aa0528f2f2 100644
--- a/Userland/Libraries/LibCore/ConfigFile.h
+++ b/Userland/Libraries/LibCore/ConfigFile.h
@@ -31,22 +31,22 @@ public:
static NonnullRefPtr<ConfigFile> open(String const& filename, int fd);
~ConfigFile();
- bool has_group(const String&) const;
- bool has_key(const String& group, const String& key) const;
+ bool has_group(String const&) const;
+ bool has_key(String const& group, String const& key) const;
Vector<String> groups() const;
- Vector<String> keys(const String& group) const;
+ Vector<String> keys(String const& group) const;
size_t num_groups() const { return m_groups.size(); }
- String read_entry(const String& group, const String& key, const String& default_value = String()) const;
- int read_num_entry(const String& group, const String& key, int default_value = 0) const;
- bool read_bool_entry(const String& group, const String& key, bool default_value = false) const;
+ String read_entry(String const& group, String const& key, String const& default_value = String()) const;
+ int read_num_entry(String const& group, String const& key, int default_value = 0) const;
+ bool read_bool_entry(String const& group, String const& key, bool default_value = false) const;
- void write_entry(const String& group, const String& key, const String& value);
- void write_num_entry(const String& group, const String& key, int value);
- void write_bool_entry(const String& group, const String& key, bool value);
- void write_color_entry(const String& group, const String& key, Color value);
+ void write_entry(String const& group, String const& key, String const& value);
+ void write_num_entry(String const& group, String const& key, int value);
+ void write_bool_entry(String const& group, String const& key, bool value);
+ void write_color_entry(String const& group, String const& key, Color value);
void dump() const;
@@ -54,8 +54,8 @@ public:
bool sync();
- void remove_group(const String& group);
- void remove_entry(const String& group, const String& key);
+ void remove_group(String const& group);
+ void remove_entry(String const& group, String const& key);
String filename() const { return m_file->filename(); }