27 lines
576 B
C++
27 lines
576 B
C++
#pragma once
|
|
#include <string>
|
|
|
|
class ServerConfiguration
|
|
{
|
|
private:
|
|
std::string wwwRoot;
|
|
std::string serverName;
|
|
int port;
|
|
bool isValid;
|
|
|
|
public:
|
|
int GetMajorVersion() const;
|
|
int GetMinorVersion() const;
|
|
std::string const & GetWwwRoot() const;
|
|
std::string const & GetServerName() const;
|
|
int GetPort() const;
|
|
bool IsValid() const;
|
|
|
|
bool LoadFromFile(std::string const & filePath);
|
|
|
|
ServerConfiguration();
|
|
~ServerConfiguration() = default;
|
|
|
|
ServerConfiguration(ServerConfiguration & other) = delete;
|
|
ServerConfiguration(ServerConfiguration && other) = delete;
|
|
}; |