215 [[nodiscard]] auto
read(const
xtd::
string& key, const
xtd::
string& default_value) ->
xtd::
string;
221 template<typename type_t>
222 [[nodiscard]] auto
read(const
xtd::
string& key, const type_t& default_value) -> type_t {
245 template<
typename type_t>
auto file_path() const noexcept -> const xtd::string &
Gets the file path of the application settings.
auto save() -> void
Save application settings.
auto write(const xtd::string &key, type_t &&value) -> void
Writes a specified value for specified key.
Definition settings.hpp:246
auto reset() -> void
Reset application settings.
auto write(const xtd::string &key, const xtd::string &value) -> void
Writes a specified value for specified key.
settings()
Initializes a new instance of settings class.
auto read(const xtd::string &key, const xtd::string &default_value) -> xtd::string
Reads a value for specified key. If not found default value is used.
Supports all classes in the xtd class hierarchy and provides low-level services to derived classes....
Definition object.hpp:45
Contains core_export_ keyword.
#define core_export_
Define shared library export.
Definition core_export.hpp:13
xtd::basic_string< char > string
Represents text as a sequence of UTF-8 code units.
Definition __string_definitions.hpp:43
xtd::shared_ptr_object< type_t > sptr
The xtd::sptr object is a shared pointer.
Definition sptr.hpp:25
auto parse(const std::string &str) -> value_t
Convert a string into a type.
Definition parse.hpp:34
Contains the types that provide the programming model for handling configuration data.
Definition file_settings.hpp:17
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition abstract_object.hpp:8
constexpr auto data() const noexcept -> const_pointer
Gets direct access to the underlying contiguous storage.
Definition read_only_span.hpp:197
Contains xtd::object class.
Contains xtd::string alias.