blob: e505797fcddbd82443fb00d357164a88d1fd541d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
#include <boost/asio.hpp>
#include <memory>
#include <sdbusplus/asio/connection.hpp>
namespace
{
std::shared_ptr<boost::asio::io_context> ioCtx;
std::shared_ptr<sdbusplus::asio::connection> sdbusp;
} // namespace
void setIoContext(std::shared_ptr<boost::asio::io_context>& newIo)
{
ioCtx = newIo;
}
std::shared_ptr<boost::asio::io_context> getIoContext()
{
return ioCtx;
}
void setSdBus(std::shared_ptr<sdbusplus::asio::connection>& newBus)
{
sdbusp = newBus;
}
std::shared_ptr<sdbusplus::asio::connection> getSdBus()
{
return sdbusp;
}
|