The Battle for Wesnoth  1.15.2+dev
credentials.hpp
Go to the documentation of this file.
1 /*
2 Copyright (C) 2017-2018 by the Battle for Wesnoth Project https://www.wesnoth.org/
3 
4 This program is free software; you can redistribute it and/or modify
5 it under the terms of the GNU General Public License as published by
6 the Free Software Foundation; either version 2 of the License, or
7 (at your option) any later version.
8 This program is distributed in the hope that it will be useful,
9 but WITHOUT ANY WARRANTY.
10 
11 See the COPYING file for more details.
12 */
13 
14 #pragma once
15 
16 #include <string>
17 
18 namespace preferences {
19  std::string login();
20  void set_login(const std::string& login);
21 
22  std::string password(const std::string& server, const std::string& login);
23  void set_password(const std::string& server, const std::string& login, const std::string& key);
24 
25  bool remember_password();
26  void set_remember_password(bool remember);
27 
28  void load_credentials();
29  void save_credentials();
30 }
bool remember_password()
void set_remember_password(bool remember)
void save_credentials()
void set_login(const std::string &login)
void set_password(const std::string &server, const std::string &login, const std::string &key)
Modify, read and display user preferences.
std::string login()
std::string password(const std::string &server, const std::string &login)
void load_credentials()