| 19 | } |
| 20 | |
| 21 | DDS::DomainParticipant* |
| 22 | OpenDDS::Model::Delegate::createParticipant( |
| 23 | unsigned long domain, |
| 24 | const DDS::DomainParticipantQos& participantQos, |
| 25 | DDS::StatusMask mask, |
| 26 | const OPENDDS_STRING& transportConfig) |
| 27 | { |
| 28 | DDS::DomainParticipantFactory_var pfact = TheParticipantFactory; |
| 29 | DDS::DomainParticipant_var participant |
| 30 | = pfact->create_participant( |
| 31 | domain, |
| 32 | participantQos, |
| 33 | DDS::DomainParticipantListener::_nil(), |
| 34 | mask |
| 35 | ); |
| 36 | // If the modeler specified a transport config, bind to it |
| 37 | if (!transportConfig.empty()) { |
| 38 | try { |
| 39 | TheTransportRegistry->bind_config(transportConfig, participant); |
| 40 | } catch (OpenDDS::DCPS::Transport::Exception&) { |
| 41 | pfact->delete_participant(participant); |
| 42 | return 0; |
| 43 | } |
| 44 | } |
| 45 | return participant; |
| 46 | } |
| 47 | |
| 48 | DDS::Topic* |
| 49 | OpenDDS::Model::Delegate::createTopic( |
no test coverage detected