@@ -9,6 +9,9 @@ Creating a DomainParticipant
99Creation of a :ref: `dds_layer_domainParticipant ` is done with the |DomainParticipantFactory::create_participant-api |
1010member function on the
1111:ref: `dds_layer_domainParticipantFactory ` singleton, that acts as a factory for the DomainParticipant.
12+ Then, when the lifecycle of the participant finishes, every participant must be deleted with
13+ |DomainParticipantFactory::delete_participant-api |.
14+ Please refer to :ref: `dds_layer_domainParticipant_deletion ` for further details on the deletion of a participant.
1215
1316Mandatory arguments are:
1417
@@ -93,16 +96,18 @@ It is advisable to check that the returned value is a valid pointer.
9396Deleting a DomainParticipant
9497----------------------------
9598
96- A DomainParticipant can be deleted with the |DomainParticipantFactory::delete_participant-api | member function on the
99+ A DomainParticipant shall be deleted with the |DomainParticipantFactory::delete_participant-api | member function on the
97100:ref: `dds_layer_domainParticipantFactory ` singleton.
98101
99- .. note ::
102+ .. important ::
100103
101104 A DomainParticipant can only be deleted if all Entities belonging to the participant
102105 (Publisher, Subscriber or Topic) have already been deleted.
103106 Otherwise, the function will issue an error and the DomainParticipant will not be deleted.
104- This can be performed by using the |DomainParticipant::delete_contained_entities-api | member function of the
105- :ref: `dds_layer_domainParticipant `.
107+ This can be performed either by using the |DomainParticipant::delete_contained_entities-api | member function of the
108+ :ref: `dds_layer_domainParticipant ` or manually deleting each entity with the corresponding *delete_ * method from the
109+ DomainParticipant e.g |DomainParticipant::delete_publisher-api |, |DomainParticipant::delete_subscriber-api |,
110+ |DomainParticipant::delete_topic-api |, etc.
106111
107112.. literalinclude :: /../code/DDSCodeTester.cpp
108113 :language: c++
0 commit comments