SNode.C
Loading...
Searching...
No Matches
web::http::client::SocketContextFactory Class Reference

#include <SocketContextFactory.h>

Inheritance diagram for web::http::client::SocketContextFactory:
Collaboration diagram for web::http::client::SocketContextFactory:

Public Types

using Request = web::http::client::Request
 
using Response = web::http::client::Response
 

Public Member Functions

 SocketContextFactory (const std::function< void(const std::shared_ptr< Request > &)> &onRequestBegin, const std::function< void(const std::shared_ptr< Request > &)> &onRequestEnd, const std::function< net::config::ConfigInstance &()> &getConfigInstance)
 
void setPipelinedRequests (bool pipelinedRequests)
 
- Public Member Functions inherited from core::socket::stream::SocketContextFactory
 SocketContextFactory (SocketContextFactory &)=delete
 
 SocketContextFactory (SocketContextFactory &&)=delete
 
SocketContextFactoryoperator= (SocketContextFactory &)=delete
 
SocketContextFactoryoperator= (SocketContextFactory &&)=delete
 

Private Member Functions

core::socket::stream::SocketContextcreate (core::socket::stream::SocketConnection *socketConnection) override
 

Private Attributes

std::function< void(const std::shared_ptr< Request > &)> onRequestBegin
 
std::function< void(const std::shared_ptr< Request > &)> onRequestEnd
 
ConfigHTTP configHttp
 

Additional Inherited Members

- Protected Member Functions inherited from web::http::SocketContextFactory< web::http::client::SocketContext >
 SocketContextFactory ()=default
 
 ~SocketContextFactory () override=default
 
- Protected Member Functions inherited from core::socket::stream::SocketContextFactory
 SocketContextFactory ()=default
 

Detailed Description

Definition at line 62 of file SocketContextFactory.h.

Member Typedef Documentation

◆ Request

◆ Response

Constructor & Destructor Documentation

◆ SocketContextFactory()

web::http::client::SocketContextFactory::SocketContextFactory ( const std::function< void(const std::shared_ptr< Request > &)> &  onRequestBegin,
const std::function< void(const std::shared_ptr< Request > &)> &  onRequestEnd,
const std::function< net::config::ConfigInstance &()> &  getConfigInstance 
)
inline

Definition at line 67 of file SocketContextFactory.h.

72 , configHttp(web::http::client::ConfigHTTP(getConfigInstance())) {
73 }
std::function< void(const std::shared_ptr< Request > &)> onRequestEnd
std::function< void(const std::shared_ptr< Request > &)> onRequestBegin

References web::http::client::ConfigHTTP::ConfigHTTP(), configHttp, onRequestBegin, and onRequestEnd.

Here is the call graph for this function:

Member Function Documentation

◆ create()

core::socket::stream::SocketContext * web::http::client::SocketContextFactory::create ( core::socket::stream::SocketConnection socketConnection)
overrideprivatevirtual

Implements core::socket::stream::SocketContextFactory.

Definition at line 50 of file SocketContextFactory.cpp.

References configHttp, web::http::client::ConfigHTTP::getPipelinedRequests(), onRequestBegin, onRequestEnd, and web::http::client::SocketContext::SocketContext().

Here is the call graph for this function:

◆ setPipelinedRequests()

void web::http::client::SocketContextFactory::setPipelinedRequests ( bool  pipelinedRequests)
inline

Definition at line 75 of file SocketContextFactory.h.

75 {
76 configHttp.setPipelinedRequests(pipelinedRequests);
77 }
void setPipelinedRequests(bool pipelinedRequests)

References configHttp, and web::http::client::ConfigHTTP::setPipelinedRequests().

Here is the call graph for this function:

Member Data Documentation

◆ configHttp

ConfigHTTP web::http::client::SocketContextFactory::configHttp
private

Definition at line 85 of file SocketContextFactory.h.

Referenced by create(), setPipelinedRequests(), and SocketContextFactory().

◆ onRequestBegin

std::function<void(const std::shared_ptr<Request>&)> web::http::client::SocketContextFactory::onRequestBegin
private

Definition at line 82 of file SocketContextFactory.h.

Referenced by create(), and SocketContextFactory().

◆ onRequestEnd

std::function<void(const std::shared_ptr<Request>&)> web::http::client::SocketContextFactory::onRequestEnd
private

Definition at line 83 of file SocketContextFactory.h.

Referenced by create(), and SocketContextFactory().


The documentation for this class was generated from the following files: