MCPcopy Create free account
hub / github.com/Icinga/icinga2 / EndpointIsConnected

Method EndpointIsConnected

lib/db_ido/endpointdbobject.cpp:83–92  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

81}
82
83int EndpointDbObject::EndpointIsConnected(const Endpoint::Ptr& endpoint)
84{
85 unsigned int is_connected = endpoint->GetConnected() ? 1 : 0;
86
87 /* if identity is equal to node, fake is_connected */
88 if (endpoint->GetName() == IcingaApplication::GetInstance()->GetNodeName())
89 is_connected = 1;
90
91 return is_connected;
92}

Callers

nothing calls this directly

Calls 3

GetConnectedMethod · 0.80
GetNodeNameMethod · 0.80
GetNameMethod · 0.45

Tested by

no test coverage detected