RMQ - RabbitMQ C++ Library
Public Member Functions | List of all members
BloombergLP::rmqtestmocks::MockRabbitContext Class Referenceabstract

Mocks rmqp::RabbitContext and/or rmqa::RabbitContext. More...

#include <rmqtestmocks_mockrabbitcontext.h>

Inheritance diagram for BloombergLP::rmqtestmocks::MockRabbitContext:
Inheritance graph
[legend]
Collaboration diagram for BloombergLP::rmqtestmocks::MockRabbitContext:
Collaboration graph
[legend]

Public Member Functions

bsl::shared_ptr< rmqa::RabbitContextcontext ()
 
 MOCK_METHOD3 (createVHostConnection, bsl::shared_ptr< rmqp::Connection >(const bsl::string &userDefinedName, const bsl::shared_ptr< rmqt::Endpoint > &endpoint, const bsl::shared_ptr< rmqt::Credentials > &credentials))
 
 MOCK_METHOD2 (createVHostConnection, bsl::shared_ptr< rmqp::Connection >(const bsl::string &userDefinedName, const rmqt::VHostInfo &vhostInfo))
 
virtual bsl::shared_ptr< Connection > createVHostConnection (const bsl::string &userDefinedName, const bsl::shared_ptr< rmqt::Endpoint > &endpoint, const bsl::shared_ptr< rmqt::Credentials > &credentials)=0
 Connect to a RabbitMQ broker. More...
 
virtual bsl::shared_ptr< Connection > createVHostConnection (const bsl::string &userDefinedName, const rmqt::VHostInfo &endpoint)=0
 Connect to a RabbitMQ broker. More...
 

Detailed Description

Mocks rmqp::RabbitContext and/or rmqa::RabbitContext.

Member Function Documentation

◆ createVHostConnection() [1/2]

virtual bsl::shared_ptr< Connection > BloombergLP::rmqp::RabbitContext::createVHostConnection ( const bsl::string &  userDefinedName,
const bsl::shared_ptr< rmqt::Endpoint > &  endpoint,
const bsl::shared_ptr< rmqt::Credentials > &  credentials 
)
pure virtualinherited

Connect to a RabbitMQ broker.

Parameters
endpointidentifies the broker to connect to
credentialsAuthentication information

Create a new rmqa::VHost to a RabbitMQ broker. Connections will be established (with the broker) when creating producers or consumers on the vhost object

Implemented in BloombergLP::rmqa::RabbitContextImpl.

◆ createVHostConnection() [2/2]

virtual bsl::shared_ptr< Connection > BloombergLP::rmqp::RabbitContext::createVHostConnection ( const bsl::string &  userDefinedName,
const rmqt::VHostInfo endpoint 
)
pure virtualinherited

Connect to a RabbitMQ broker.

Parameters
vhostInfoidentifies the broker to connect to & authentication details

Create a new rmqa::VHost to a RabbitMQ broker. Connections will be established (with the broker) when creating producers or consumers on the vhost object

Implemented in BloombergLP::rmqa::RabbitContextImpl.


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