The Battle for Wesnoth  1.17.0-dev
Macros | Functions | Variables
server_base.cpp File Reference
#include "server/common/server_base.hpp"
#include "config.hpp"
#include "hash.hpp"
#include "log.hpp"
#include "serialization/parser.hpp"
#include "serialization/base64.hpp"
#include "filesystem.hpp"
#include <boost/asio/ip/v6_only.hpp>
#include <boost/asio/read.hpp>
#include <boost/asio/read_until.hpp>
#include <boost/asio/write.hpp>
#include <array>
#include <ctime>
#include <functional>
#include <queue>
#include <sstream>
#include <string>
#include "game_version.hpp"
#include "deprecation.hpp"
Include dependency graph for server_base.cpp:

Go to the source code of this file.

Macros

#define ERR_SERVER   LOG_STREAM(err, log_server)
 
#define WRN_SERVER   LOG_STREAM(warn, log_server)
 
#define LOG_SERVER   LOG_STREAM(info, log_server)
 
#define DBG_SERVER   LOG_STREAM(debug, log_server)
 
#define ERR_CONFIG   LOG_STREAM(err, log_config)
 
#define WRN_CONFIG   LOG_STREAM(warn, log_config)
 

Functions

template<class SocketPtr >
std::string client_address (SocketPtr socket)
 
template<class SocketPtr >
bool check_error (const boost::system::error_code &error, SocketPtr socket)
 
template bool check_error< tls_socket_ptr > (const boost::system::error_code &error, tls_socket_ptr socket)
 
template<class SocketPtr >
void coro_send_file_userspace (SocketPtr socket, const std::string &filename, boost::asio::yield_context yield)
 
std::string deprecated_message (const std::string &, DEP_LEVEL, const version_info &, const std::string &)
 

Variables

static lg::log_domain log_server ("server")
 
static lg::log_domain log_config ("config")
 
bool dump_wml = false
 

Macro Definition Documentation

◆ DBG_SERVER

#define DBG_SERVER   LOG_STREAM(debug, log_server)

Definition at line 57 of file server_base.cpp.

Referenced by server_base::serve().

◆ ERR_CONFIG

#define ERR_CONFIG   LOG_STREAM(err, log_config)

Definition at line 60 of file server_base.cpp.

◆ ERR_SERVER

#define ERR_SERVER   LOG_STREAM(err, log_server)

◆ LOG_SERVER

#define LOG_SERVER   LOG_STREAM(info, log_server)

◆ WRN_CONFIG

#define WRN_CONFIG   LOG_STREAM(warn, log_config)

Definition at line 61 of file server_base.cpp.

Referenced by server_base::coro_send_doc().

◆ WRN_SERVER

#define WRN_SERVER   LOG_STREAM(warn, log_server)

Definition at line 55 of file server_base.cpp.

Function Documentation

◆ check_error()

template<class SocketPtr >
bool check_error ( const boost::system::error_code &  error,
SocketPtr  socket 
)

◆ check_error< tls_socket_ptr >()

template bool check_error< tls_socket_ptr > ( const boost::system::error_code &  error,
tls_socket_ptr  socket 
)

Referenced by check_error().

◆ client_address()

template<class SocketPtr >
std::string client_address ( SocketPtr  socket)

Definition at line 238 of file server_base.cpp.

References error().

Referenced by log_address(), and server_base::serve().

◆ coro_send_file_userspace()

template<class SocketPtr >
void coro_send_file_userspace ( SocketPtr  socket,
const std::string &  filename,
boost::asio::yield_context  yield 
)

◆ deprecated_message()

std::string deprecated_message ( const std::string &  ,
DEP_LEVEL  ,
const version_info ,
const std::string &   
)

Definition at line 612 of file server_base.cpp.

Variable Documentation

◆ dump_wml

bool dump_wml = false

Definition at line 63 of file server_base.cpp.

Referenced by server_base::coro_send_doc(), and main().

◆ log_config

lg::log_domain log_config("config")
static

◆ log_server

lg::log_domain log_server("server")
static