17#ifndef CYBER_SERVICE_DISCOVERY_TOPOLOGY_MANAGER_H_
18#define CYBER_SERVICE_DISCOVERY_TOPOLOGY_MANAGER_H_
37namespace service_discovery {
71 std::map<eprosima::fastrtps::rtps::GUID_t, std::string>;
112 bool InitNodeManager();
113 bool InitChannelManager();
114 bool InitServiceManager();
116 bool CreateParticipant();
117 void OnParticipantChange(
118 const eprosima::fastrtps::rtps::ParticipantDiscoveryInfo& info);
119 bool Convert(
const eprosima::fastrtps::rtps::ParticipantDiscoveryInfo& info,
121 bool ParseParticipantName(
const std::string& participant_name,
122 std::string* host_name,
int* process_id);
124 std::atomic<bool> init_;
Topology Manager of Service related
Topology Manager of Service related
elements in Cyber – Node, Channel, Service, Writer, Reader, Client and Server's relationship is prese...
void RemoveChangeListener(const ChangeConnection &conn)
Remove the observe function connect to change_signal_ by conn
ChangeConnection AddChangeListener(const ChangeFunc &func)
To observe the topology change, you can register a ChangeFunc
std::shared_ptr< transport::Participant > ParticipantPtr
std::function< void(const ChangeMsg &)> ChangeFunc
void Shutdown()
Shutdown the TopologyManager
base::Signal< const ChangeMsg & > ChangeSignal
ServiceManagerPtr & service_manager()
Get shared_ptr for ServiceManager
NodeManagerPtr & node_manager()
Get shared_ptr for NodeManager
std::map< eprosima::fastrtps::rtps::GUID_t, std::string > PartNameContainer
ChannelManagerPtr & channel_manager()
Get shared_ptr for ChannelManager
virtual ~TopologyManager()
#define DECLARE_SINGLETON(classname)
std::shared_ptr< ChannelManager > ChannelManagerPtr
std::shared_ptr< NodeManager > NodeManagerPtr
std::shared_ptr< ServiceManager > ServiceManagerPtr