MCPcopy Create free account
hub / github.com/OpenVPN/openvpn3-linux / Log

Method Log

src/dbus/signals/log.cpp:22–49  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

20namespace Signals {
21
22Log::Log(DBus::Signals::Emit::Ptr emitter,
23 DBus::Signals::SubscriptionManager::Ptr subscr,
24 DBus::Signals::Target::Ptr subscr_tgt)
25 : DBus::Signals::Signal(emitter, "Log"),
26 target(subscr_tgt)
27{
28 SetArguments(Events::Log::SignalDeclaration());
29
30 // Prepare proxying incoming StatusChange signals
31 if (subscr && subscr_tgt)
32 {
33 subscr->Subscribe(target,
34 "Log",
35 [=](DBus::Signals::Event::Ptr event)
36 {
37 try
38 {
39 Events::Log ev = Events::ParseLog(event->params);
40 (void)Send(ev);
41 }
42 catch (const DBus::Exception &ex)
43 {
44 std::cerr << "Log EXCEPTION:"
45 << ex.what() << std::endl;
46 }
47 });
48 }
49}
50
51
52const std::string Log::GetSignature() const

Callers

nothing calls this directly

Calls 3

ParseLogFunction · 0.85
SubscribeMethod · 0.80
whatMethod · 0.45

Tested by

no test coverage detected