MQTTSuite
Loading...
Searching...
No Matches
mqtt::mqttbroker::SocketContextFactory Class Reference

#include <SocketContextFactory.h>

Inheritance diagram for mqtt::mqttbroker::SocketContextFactory:
Collaboration diagram for mqtt::mqttbroker::SocketContextFactory:

Public Member Functions

 SocketContextFactory (const std::shared_ptr< iot::mqtt::server::broker::Broker > broker)
core::socket::stream::SocketContext * create (core::socket::stream::SocketConnection *socketConnection) final

Private Attributes

const std::shared_ptr< iot::mqtt::server::broker::Broker > broker

Detailed Description

Definition at line 59 of file SocketContextFactory.h.

Constructor & Destructor Documentation

◆ SocketContextFactory()

mqtt::mqttbroker::SocketContextFactory::SocketContextFactory ( const std::shared_ptr< iot::mqtt::server::broker::Broker > broker)
explicit

Definition at line 59 of file SocketContextFactory.cpp.

60 : broker(broker) {
61 }
const std::shared_ptr< iot::mqtt::server::broker::Broker > broker

Member Function Documentation

◆ create()

core::socket::stream::SocketContext * mqtt::mqttbroker::SocketContextFactory::create ( core::socket::stream::SocketConnection * socketConnection)
final

Definition at line 63 of file SocketContextFactory.cpp.

63 {
64 return new iot::mqtt::SocketContext(
65 socketConnection,
66 new mqtt::mqttbroker::lib::Mqtt(socketConnection->getConnectionName(),
67 broker,
68 utils::Config::configRoot.getSubCommand<mqtt::lib::ConfigMqttBroker>()->getMqttMapper()));
69 }

References mqtt::lib::ConfigApplication::getMqttMapper(), and mqtt::mqttbroker::lib::Mqtt::Mqtt().

Here is the call graph for this function:

Member Data Documentation

◆ broker

const std::shared_ptr<iot::mqtt::server::broker::Broker> mqtt::mqttbroker::SocketContextFactory::broker
private

Definition at line 66 of file SocketContextFactory.h.


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