#pragma once #include namespace smtp::service { struct SettingsFields { bool is_need_auth; bool is_need_ssl; std::string username; std::string password; std::string host; std::string port; }; class Settings { public: Settings(); explicit Settings( SettingsFields data ); ~Settings() = default; bool CheckAndSetSettings( SettingsFields data ); bool IsNeedAuth() const noexcept; bool IsNeedSsl() const noexcept; std::string GetUserName() const; std::string GetPassword() const; std::string GetHost() const; std::string GetPort() const; private: SettingsFields mSettingsFields; }; }