Change 'typedef' constructions to type aliases
This commit is contained in:
parent
a3d70bbcb5
commit
3ab6cd8a39
8 changed files with 11 additions and 11 deletions
|
|
@ -594,7 +594,7 @@ namespace SimpleWeb {
|
|||
template <class socket_type>
|
||||
class Client : public ClientBase<socket_type> {};
|
||||
|
||||
typedef asio::ip::tcp::socket HTTP;
|
||||
using HTTP = asio::ip::tcp::socket;
|
||||
|
||||
template <>
|
||||
class Client<HTTP> : public ClientBase<HTTP> {
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
#endif
|
||||
|
||||
namespace SimpleWeb {
|
||||
typedef asio::ssl::stream<asio::ip::tcp::socket> HTTPS;
|
||||
using HTTPS = asio::ssl::stream<asio::ip::tcp::socket>;
|
||||
|
||||
template <>
|
||||
class Client<HTTPS> : public ClientBase<HTTPS> {
|
||||
|
|
|
|||
|
|
@ -19,8 +19,8 @@ using namespace std;
|
|||
// Added for the json-example:
|
||||
using namespace boost::property_tree;
|
||||
|
||||
typedef SimpleWeb::Server<SimpleWeb::HTTP> HttpServer;
|
||||
typedef SimpleWeb::Client<SimpleWeb::HTTP> HttpClient;
|
||||
using HttpServer = SimpleWeb::Server<SimpleWeb::HTTP>;
|
||||
using HttpClient = SimpleWeb::Client<SimpleWeb::HTTP>;
|
||||
|
||||
int main() {
|
||||
// HTTP-server at port 8080 using 1 thread
|
||||
|
|
|
|||
|
|
@ -17,8 +17,8 @@ using namespace std;
|
|||
// Added for the json-example:
|
||||
using namespace boost::property_tree;
|
||||
|
||||
typedef SimpleWeb::Server<SimpleWeb::HTTPS> HttpsServer;
|
||||
typedef SimpleWeb::Client<SimpleWeb::HTTPS> HttpsClient;
|
||||
using HttpsServer = SimpleWeb::Server<SimpleWeb::HTTPS>;
|
||||
using HttpsClient = SimpleWeb::Client<SimpleWeb::HTTPS>;
|
||||
|
||||
int main() {
|
||||
// HTTPS-server at port 8080 using 1 thread
|
||||
|
|
|
|||
|
|
@ -551,7 +551,7 @@ namespace SimpleWeb {
|
|||
template <class socket_type>
|
||||
class Server : public ServerBase<socket_type> {};
|
||||
|
||||
typedef asio::ip::tcp::socket HTTP;
|
||||
using HTTP = asio::ip::tcp::socket;
|
||||
|
||||
template <>
|
||||
class Server<HTTP> : public ServerBase<HTTP> {
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@
|
|||
#include <openssl/ssl.h>
|
||||
|
||||
namespace SimpleWeb {
|
||||
typedef asio::ssl::stream<asio::ip::tcp::socket> HTTPS;
|
||||
using HTTPS = asio::ssl::stream<asio::ip::tcp::socket>;
|
||||
|
||||
template <>
|
||||
class Server<HTTPS> : public ServerBase<HTTPS> {
|
||||
|
|
|
|||
|
|
@ -9,8 +9,8 @@ using namespace std;
|
|||
namespace asio = boost::asio;
|
||||
#endif
|
||||
|
||||
typedef SimpleWeb::Server<SimpleWeb::HTTP> HttpServer;
|
||||
typedef SimpleWeb::Client<SimpleWeb::HTTP> HttpClient;
|
||||
using HttpServer = SimpleWeb::Server<SimpleWeb::HTTP>;
|
||||
using HttpClient = SimpleWeb::Client<SimpleWeb::HTTP>;
|
||||
|
||||
int main() {
|
||||
// Test ScopeRunner
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ namespace SimpleWeb {
|
|||
}
|
||||
};
|
||||
|
||||
typedef std::unordered_multimap<std::string, std::string, CaseInsensitiveHash, CaseInsensitiveEqual> CaseInsensitiveMultimap;
|
||||
using CaseInsensitiveMultimap = std::unordered_multimap<std::string, std::string, CaseInsensitiveHash, CaseInsensitiveEqual>;
|
||||
|
||||
/// Percent encoding and decoding
|
||||
class Percent {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue