20#ifndef FASTDDS_DDS_DOMAIN__DOMAINPARTICIPANTFACTORY_HPP
21#define FASTDDS_DDS_DOMAIN__DOMAINPARTICIPANTFACTORY_HPP
27#include <fastdds/dds/core/ReturnCode.hpp>
28#include <fastdds/dds/core/status/StatusMask.hpp>
29#include <fastdds/dds/domain/qos/DomainParticipantExtendedQos.hpp>
30#include <fastdds/dds/domain/qos/DomainParticipantFactoryQos.hpp>
31#include <fastdds/dds/domain/qos/DomainParticipantQos.hpp>
32#include <fastdds/dds/xtypes/dynamic_types/DynamicType.hpp>
33#include <fastdds/dds/xtypes/dynamic_types/DynamicTypeBuilder.hpp>
34#include <fastdds/dds/xtypes/type_representation/ITypeObjectRegistry.hpp>
35#include <fastdds/LibrarySettings.hpp>
45class TopicPayloadPoolRegistry;
51class DomainParticipantListener;
52class DomainParticipant;
53class DomainParticipantImpl;
141 const std::string& profile_name,
154 const std::string& profile_name,
229 const std::string& profile_name,
240 const std::string& profile_name,
276 const std::string& xml_profile_file);
296 std::string& xml_file);
356 const std::string& type_name,
397 DomainParticipantImpl* part);
409 std::shared_ptr<fastdds::rtps::detail::TopicPayloadPoolRegistry>
topic_pool_;
Class LibraySettings, used by the user to define the Fast DDS library behaviour.
Definition LibrarySettings.hpp:38
Definition DomainParticipantExtendedQos.hpp:32
Class DomainParticipantFactory.
Definition DomainParticipantFactory.hpp:65
static void set_qos(DomainParticipantFactoryQos &to, const DomainParticipantFactoryQos &from, bool first_time)
FASTDDS_EXPORTED_API DomainParticipant * create_participant_with_default_profile(DomainParticipantListener *listener, const StatusMask &mask)
Create a Participant with default domain id and qos.
bool default_xml_profiles_loaded
Definition DomainParticipantFactory.hpp:401
std::shared_ptr< fastdds::rtps::detail::TopicPayloadPoolRegistry > topic_pool_
Definition DomainParticipantFactory.hpp:409
DomainParticipantFactory(const DomainParticipantFactory &)=delete
FASTDDS_EXPORTED_API ReturnCode_t set_library_settings(const LibrarySettings &library_settings)
This operation sets the library settings.
FASTDDS_EXPORTED_API ReturnCode_t set_qos(const DomainParticipantFactoryQos &qos)
This operation sets the value of the DomainParticipantFactory QoS policies.
virtual ~DomainParticipantFactory()
void operator=(const DomainParticipantFactory &)=delete
FASTDDS_EXPORTED_API ReturnCode_t get_library_settings(LibrarySettings &library_settings) const
This operation returns the value of the DomainParticipant library settings.
FASTDDS_EXPORTED_API DomainParticipant * create_participant_with_profile(const std::string &profile_name, DomainParticipantListener *listener=nullptr, const StatusMask &mask=StatusMask::all())
Create a Participant.
std::mutex default_xml_profiles_loaded_mtx_
This mutex guards the access to load the profiles.
Definition DomainParticipantFactory.hpp:420
FASTDDS_EXPORTED_API ReturnCode_t get_qos(DomainParticipantFactoryQos &qos) const
This operation returns the value of the DomainParticipantFactory QoS policies.
FASTDDS_EXPORTED_API DomainParticipant * lookup_participant(DomainId_t domain_id) const
This operation retrieves a previously created DomainParticipant belonging to specified domain_id.
FASTDDS_EXPORTED_API DomainParticipant * create_participant_with_profile(DomainId_t domain_id, const std::string &profile_name, DomainParticipantListener *listener=nullptr, const StatusMask &mask=StatusMask::all())
Create a Participant.
FASTDDS_EXPORTED_API ReturnCode_t load_XML_profiles_file(const std::string &xml_profile_file)
Load profiles from XML file.
std::mutex mtx_participants_
Definition DomainParticipantFactory.hpp:399
std::map< DomainId_t, std::vector< DomainParticipantImpl * > > participants_
Definition DomainParticipantFactory.hpp:370
DomainParticipantQos default_participant_qos_
Definition DomainParticipantFactory.hpp:407
FASTDDS_EXPORTED_API ReturnCode_t set_default_participant_qos(const DomainParticipantQos &qos)
This operation sets a default value of the DomainParticipant QoS policies which will be used for newl...
FASTDDS_EXPORTED_API DomainParticipant * create_participant(DomainId_t domain_id, const DomainParticipantQos &qos, DomainParticipantListener *listener=nullptr, const StatusMask &mask=StatusMask::all())
Create a Participant.
DomainParticipantFactory()
std::shared_ptr< fastdds::rtps::RTPSDomainImpl > rtps_domain_
Definition DomainParticipantFactory.hpp:411
FASTDDS_EXPORTED_API const DomainParticipantQos & get_default_participant_qos() const
This operation retrieves the default value of the DomainParticipant QoS, that is, the QoS policies wh...
FASTDDS_EXPORTED_API DomainParticipant * create_participant_with_default_profile()
Create a Participant with default domain id and qos.
DomainParticipantFactoryQos factory_qos_
Definition DomainParticipantFactory.hpp:405
static FASTDDS_EXPORTED_API std::shared_ptr< DomainParticipantFactory > get_shared_instance()
Returns the DomainParticipantFactory singleton instance.
FASTDDS_EXPORTED_API ReturnCode_t get_participant_extended_qos_from_default_profile(DomainParticipantExtendedQos &extended_qos) const
Fills the DomainParticipantExtendedQos with the values of the default XML profile.
FASTDDS_EXPORTED_API ReturnCode_t get_dynamic_type_builder_from_xml_by_name(const std::string &type_name, DynamicTypeBuilder::_ref_type &type)
Get the DynamicType defined in XML file.
static FASTDDS_EXPORTED_API DomainParticipantFactory * get_instance()
Returns the DomainParticipantFactory singleton instance.
FASTDDS_EXPORTED_API ReturnCode_t get_default_participant_qos(DomainParticipantQos &qos) const
This operation retrieves the default value of the DomainParticipant QoS, that is, the QoS policies wh...
FASTDDS_EXPORTED_API ReturnCode_t get_participant_qos_from_profile(const std::string &profile_name, DomainParticipantQos &qos) const
Fills the DomainParticipantQos with the values of the XML profile.
void participant_has_been_deleted(DomainParticipantImpl *part)
std::shared_ptr< detail::LogResources > log_resources_
Definition DomainParticipantFactory.hpp:413
FASTDDS_EXPORTED_API ReturnCode_t load_XML_profiles_string(const char *data, size_t length)
Load profiles from XML string.
static bool can_qos_be_updated(const DomainParticipantFactoryQos &to, const DomainParticipantFactoryQos &from)
FASTDDS_EXPORTED_API ReturnCode_t delete_participant(DomainParticipant *part)
Remove a Participant and all associated publishers and subscribers.
void reset_default_participant_qos()
DomainId_t default_domain_id_
Definition DomainParticipantFactory.hpp:403
FASTDDS_EXPORTED_API DomainParticipant * create_participant(const DomainParticipantExtendedQos &extended_qos, DomainParticipantListener *listener=nullptr, const StatusMask &mask=StatusMask::all())
Create a Participant.
FASTDDS_EXPORTED_API xtypes::ITypeObjectRegistry & type_object_registry()
Return the TypeObjectRegistry member to access the public API.
FASTDDS_EXPORTED_API ReturnCode_t load_profiles()
Load profiles from default XML file.
FASTDDS_EXPORTED_API ReturnCode_t check_xml_static_discovery(std::string &xml_file)
Check the validity of the provided static discovery XML file.
static ReturnCode_t check_qos(const DomainParticipantFactoryQos &qos)
FASTDDS_EXPORTED_API std::vector< DomainParticipant * > lookup_participants(DomainId_t domain_id) const
Returns all participants that belongs to the specified domain_id.
FASTDDS_EXPORTED_API ReturnCode_t get_participant_extended_qos_from_profile(const std::string &profile_name, DomainParticipantExtendedQos &extended_qos) const
Fills the DomainParticipantExtendedQos with the values of the XML profile.
Class DomainParticipantFactoryQos, contains all the possible Qos that can be set for a determined par...
Definition DomainParticipantFactoryQos.hpp:37
Class DomainParticipant used to group Publishers and Subscribers into a single working unit.
Definition DomainParticipant.hpp:78
Class DomainParticipantListener, overrides behaviour towards certain events.
Definition DomainParticipantListener.hpp:49
Class DomainParticipantQos, contains all the possible Qos that can be set for a determined participan...
Definition DomainParticipantQos.hpp:42
typename traits< DynamicTypeBuilder >::ref_type _ref_type
Definition DynamicTypeBuilder.hpp:35
StatusMask is a bitmap or bitset field.
Definition StatusMask.hpp:48
static StatusMask all()
Get all StatusMasks.
Definition StatusMask.hpp:104
Definition ITypeObjectRegistry.hpp:45
Definition DomainParticipant.hpp:45
uint32_t DomainId_t
Definition Types.hpp:24
int32_t ReturnCode_t
Definition DDSReturnCode.hpp:59