xrpld
Loading...
Searching...
No Matches
xrpl::detail::WorkSSL Class Reference

#include <WorkSSL.h>

Inheritance diagram for xrpl::detail::WorkSSL:
Collaboration diagram for xrpl::detail::WorkSSL:

Public Types

using callback_type

Public Member Functions

 WorkSSL (std::string const &host, std::string const &path, std::string const &port, boost::asio::io_context &ios, beast::Journal j, Config const &config, endpoint_type const &lastEndpoint, bool lastStatus, callback_type cb)
 ~WorkSSL () override=default
WorkSSLimpl ()
void run () override
void cancel () override
void fail (error_code const &ec)
void onResolve (error_code const &ec, results_type results)
void onConnect (error_code const &ec, endpoint_type const &endpoint)
void onStart ()
void onRequest (error_code const &ec)
void onResponse (error_code const &ec)
shared_from_this (T... args)
weak_from_this (T... args)

Protected Types

using error_code
using endpoint_type
using socket_type
using resolver_type
using results_type
using request_type

Protected Attributes

std::string host_
std::string path_
std::string port_
callback_type cb_
boost::asio::io_context & ios_
boost::asio::strand< boost::asio::io_context::executor_type > strand_
resolver_type resolver_
socket_type socket_
request_type req_
response_type res_
boost::beast::multi_buffer readBuf_
endpoint_type lastEndpoint_
bool lastStatus_

Private Types

using stream_type = boost::asio::ssl::stream<socket_type&>

Private Member Functions

stream_typestream ()
void onConnect (error_code const &ec)
void onHandshake (error_code const &ec)
void close ()

Private Attributes

HTTPClientSSLContext context_
stream_type stream_
friend Impl

Friends

class WorkBase< WorkSSL >

Detailed Description

Definition at line 17 of file WorkSSL.h.

Member Typedef Documentation

◆ stream_type

using xrpl::detail::WorkSSL::stream_type = boost::asio::ssl::stream<socket_type&>
private

Definition at line 22 of file WorkSSL.h.

◆ error_code

using xrpl::detail::WorkBase< WorkSSL >::error_code
protectedinherited

Definition at line 23 of file WorkBase.h.

◆ endpoint_type

using xrpl::detail::WorkBase< WorkSSL >::endpoint_type
protectedinherited

Definition at line 24 of file WorkBase.h.

◆ callback_type

using xrpl::detail::WorkBase< WorkSSL >::callback_type
inherited

Definition at line 27 of file WorkBase.h.

◆ socket_type

using xrpl::detail::WorkBase< WorkSSL >::socket_type
protectedinherited

Definition at line 31 of file WorkBase.h.

◆ resolver_type

using xrpl::detail::WorkBase< WorkSSL >::resolver_type
protectedinherited

Definition at line 32 of file WorkBase.h.

◆ results_type

using xrpl::detail::WorkBase< WorkSSL >::results_type
protectedinherited

Definition at line 33 of file WorkBase.h.

◆ request_type

using xrpl::detail::WorkBase< WorkSSL >::request_type
protectedinherited

Definition at line 34 of file WorkBase.h.

Constructor & Destructor Documentation

◆ WorkSSL()

xrpl::detail::WorkSSL::WorkSSL ( std::string const & host,
std::string const & path,
std::string const & port,
boost::asio::io_context & ios,
beast::Journal j,
Config const & config,
endpoint_type const & lastEndpoint,
bool lastStatus,
callback_type cb )

Definition at line 21 of file WorkSSL.cpp.

◆ ~WorkSSL()

xrpl::detail::WorkSSL::~WorkSSL ( )
overridedefault

Member Function Documentation

◆ stream()

stream_type & xrpl::detail::WorkSSL::stream ( )
private

Definition at line 42 of file WorkSSL.h.

◆ onConnect() [1/2]

void xrpl::detail::WorkSSL::onConnect ( error_code const & ec)
private

Definition at line 46 of file WorkSSL.cpp.

◆ onHandshake()

void xrpl::detail::WorkSSL::onHandshake ( error_code const & ec)
private

Definition at line 62 of file WorkSSL.cpp.

◆ impl()

WorkSSL & xrpl::detail::WorkBase< WorkSSL >::impl ( )
inherited

Definition at line 64 of file WorkBase.h.

◆ run()

void xrpl::detail::WorkBase< WorkSSL >::run ( )
overridevirtualinherited

Implements xrpl::detail::Work.

Definition at line 70 of file WorkBase.h.

◆ cancel()

void xrpl::detail::WorkBase< WorkSSL >::cancel ( )
overridevirtualinherited

Implements xrpl::detail::Work.

Definition at line 73 of file WorkBase.h.

◆ fail()

void xrpl::detail::WorkBase< WorkSSL >::fail ( error_code const & ec)
inherited

Definition at line 76 of file WorkBase.h.

◆ onResolve()

void xrpl::detail::WorkBase< WorkSSL >::onResolve ( error_code const & ec,
results_type results )
inherited

Definition at line 79 of file WorkBase.h.

◆ onConnect() [2/2]

void xrpl::detail::WorkBase< WorkSSL >::onConnect ( error_code const & ec,
endpoint_type const & endpoint )
inherited

Definition at line 82 of file WorkBase.h.

◆ onStart()

void xrpl::detail::WorkBase< WorkSSL >::onStart ( )
inherited

Definition at line 85 of file WorkBase.h.

◆ onRequest()

void xrpl::detail::WorkBase< WorkSSL >::onRequest ( error_code const & ec)
inherited

Definition at line 88 of file WorkBase.h.

◆ onResponse()

void xrpl::detail::WorkBase< WorkSSL >::onResponse ( error_code const & ec)
inherited

Definition at line 91 of file WorkBase.h.

◆ close()

void xrpl::detail::WorkBase< WorkSSL >::close ( )
privateinherited

Definition at line 95 of file WorkBase.h.

◆ WorkBase< WorkSSL >

friend class WorkBase< WorkSSL >
friend

Definition at line 1 of file WorkSSL.h.

Member Data Documentation

◆ context_

HTTPClientSSLContext xrpl::detail::WorkSSL::context_
private

Definition at line 24 of file WorkSSL.h.

◆ stream_

stream_type xrpl::detail::WorkSSL::stream_
private

Definition at line 25 of file WorkSSL.h.

◆ host_

std::string xrpl::detail::WorkBase< WorkSSL >::host_
protectedinherited

Definition at line 36 of file WorkBase.h.

◆ path_

std::string xrpl::detail::WorkBase< WorkSSL >::path_
protectedinherited

Definition at line 37 of file WorkBase.h.

◆ port_

std::string xrpl::detail::WorkBase< WorkSSL >::port_
protectedinherited

Definition at line 38 of file WorkBase.h.

◆ cb_

callback_type xrpl::detail::WorkBase< WorkSSL >::cb_
protectedinherited

Definition at line 39 of file WorkBase.h.

◆ ios_

boost::asio::io_context& xrpl::detail::WorkBase< WorkSSL >::ios_
protectedinherited

Definition at line 40 of file WorkBase.h.

◆ strand_

boost::asio::strand<boost::asio::io_context::executor_type> xrpl::detail::WorkBase< WorkSSL >::strand_
protectedinherited

Definition at line 41 of file WorkBase.h.

◆ resolver_

resolver_type xrpl::detail::WorkBase< WorkSSL >::resolver_
protectedinherited

Definition at line 42 of file WorkBase.h.

◆ socket_

socket_type xrpl::detail::WorkBase< WorkSSL >::socket_
protectedinherited

Definition at line 43 of file WorkBase.h.

◆ req_

request_type xrpl::detail::WorkBase< WorkSSL >::req_
protectedinherited

Definition at line 44 of file WorkBase.h.

◆ res_

response_type xrpl::detail::WorkBase< WorkSSL >::res_
protectedinherited

Definition at line 45 of file WorkBase.h.

◆ readBuf_

boost::beast::multi_buffer xrpl::detail::WorkBase< WorkSSL >::readBuf_
protectedinherited

Definition at line 46 of file WorkBase.h.

◆ lastEndpoint_

endpoint_type xrpl::detail::WorkBase< WorkSSL >::lastEndpoint_
protectedinherited

Definition at line 47 of file WorkBase.h.

◆ lastStatus_

bool xrpl::detail::WorkBase< WorkSSL >::lastStatus_
protectedinherited

Definition at line 48 of file WorkBase.h.

◆ Impl

friend xrpl::detail::WorkBase< WorkSSL >::WorkSSL
privateinherited

Definition at line 97 of file WorkBase.h.