init
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
#ifndef OMG_DDS_DOMAIN_DETAIL_DOMAINPARTICIPANT_HPP_
|
||||
#define OMG_DDS_DOMAIN_DETAIL_DOMAINPARTICIPANT_HPP_
|
||||
|
||||
/* Copyright 2010, Object Management Group, Inc.
|
||||
* Copyright 2010, PrismTech, Corp.
|
||||
* Copyright 2010, Real-Time Innovations, Inc.
|
||||
* All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <dds/domain/detail/TDomainParticipantImpl.hpp>
|
||||
//#include <dds/domain/TDomainParticipant.hpp>
|
||||
//#include <org/eclipse/cyclonedds/domain/DomainParticipantDelegate.hpp>
|
||||
|
||||
namespace dds {
|
||||
namespace domain {
|
||||
namespace detail {
|
||||
typedef dds::domain::TDomainParticipant< org::eclipse::cyclonedds::domain::DomainParticipantDelegate >
|
||||
DomainParticipant;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* OMG_DDS_DOMAIN_DETAIL_DOMAINPARTICIPANT_HPP_ */
|
@@ -0,0 +1,193 @@
|
||||
/*
|
||||
* Copyright(c) 2006 to 2021 ZettaScale Technology and others
|
||||
*
|
||||
* This program and the accompanying materials are made available under the
|
||||
* terms of the Eclipse Public License v. 2.0 which is available at
|
||||
* http://www.eclipse.org/legal/epl-2.0, or the Eclipse Distribution License
|
||||
* v. 1.0 which is available at
|
||||
* http://www.eclipse.org/org/documents/edl-v10.php.
|
||||
*
|
||||
* SPDX-License-Identifier: EPL-2.0 OR BSD-3-Clause
|
||||
*/
|
||||
#ifndef CYCLONEDDS_DDS_DOMAIN_TDOMAINPARTICIPANT_IMPL_HPP_
|
||||
#define CYCLONEDDS_DDS_DOMAIN_TDOMAINPARTICIPANT_IMPL_HPP_
|
||||
|
||||
/**
|
||||
* @file
|
||||
*/
|
||||
|
||||
/*
|
||||
* OMG PSM class declaration
|
||||
*/
|
||||
#include <dds/domain/TDomainParticipant.hpp>
|
||||
#include <org/eclipse/cyclonedds/domain/DomainParticipantDelegate.hpp>
|
||||
#include <org/eclipse/cyclonedds/domain/DomainParticipantRegistry.hpp>
|
||||
#include <org/eclipse/cyclonedds/core/ReportUtils.hpp>
|
||||
|
||||
|
||||
// Implementation
|
||||
|
||||
namespace dds
|
||||
{
|
||||
namespace domain
|
||||
{
|
||||
|
||||
template <typename DELEGATE>
|
||||
TDomainParticipant<DELEGATE>::TDomainParticipant(uint32_t did):
|
||||
::dds::core::Reference<DELEGATE>(
|
||||
new DELEGATE(did,
|
||||
org::eclipse::cyclonedds::domain::DomainParticipantDelegate::default_participant_qos(),
|
||||
NULL,
|
||||
dds::core::status::StatusMask::none(),
|
||||
std::string()))
|
||||
{
|
||||
this->delegate()->init(this->impl_);
|
||||
org::eclipse::cyclonedds::domain::DomainParticipantRegistry::insert(*this);
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
TDomainParticipant<DELEGATE>::TDomainParticipant(uint32_t id,
|
||||
const dds::domain::qos::DomainParticipantQos& qos,
|
||||
dds::domain::DomainParticipantListener* listener,
|
||||
const dds::core::status::StatusMask& mask,
|
||||
const std::string& config) :
|
||||
::dds::core::Reference<DELEGATE>(new DELEGATE(id, qos, listener, mask, config))
|
||||
{
|
||||
this->delegate()->init(this->impl_);
|
||||
org::eclipse::cyclonedds::domain::DomainParticipantRegistry::insert(*this);
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
TDomainParticipant<DELEGATE>::TDomainParticipant(uint32_t id,
|
||||
const dds::domain::qos::DomainParticipantQos& qos,
|
||||
dds::domain::DomainParticipantListener* listener,
|
||||
const dds::core::status::StatusMask& mask,
|
||||
const ddsi_config& config) :
|
||||
::dds::core::Reference<DELEGATE>(new DELEGATE(id, qos, listener, mask, config))
|
||||
{
|
||||
this->delegate()->init(this->impl_);
|
||||
org::eclipse::cyclonedds::domain::DomainParticipantRegistry::insert(*this);
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
void TDomainParticipant<DELEGATE>::listener(Listener* listener,
|
||||
const ::dds::core::status::StatusMask& event_mask)
|
||||
{
|
||||
this->delegate()->listener(listener, event_mask);
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
typename TDomainParticipant<DELEGATE>::Listener* TDomainParticipant<DELEGATE>::listener() const
|
||||
{
|
||||
return this->delegate()->listener();
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
const dds::domain::qos::DomainParticipantQos&
|
||||
TDomainParticipant<DELEGATE>::qos() const
|
||||
{
|
||||
return this->delegate()->qos();
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
void TDomainParticipant<DELEGATE>::qos(const dds::domain::qos::DomainParticipantQos& qos)
|
||||
{
|
||||
this->delegate()->qos(qos);
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
uint32_t TDomainParticipant<DELEGATE>::domain_id() const
|
||||
{
|
||||
return this->delegate()->domain_id();
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
void TDomainParticipant<DELEGATE>::assert_liveliness()
|
||||
{
|
||||
this->delegate()->assert_liveliness();
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
bool TDomainParticipant<DELEGATE>::contains_entity(const ::dds::core::InstanceHandle& handle)
|
||||
{
|
||||
return this->delegate()->contains_entity(handle);
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
dds::core::Time TDomainParticipant<DELEGATE>::current_time() const
|
||||
{
|
||||
return this->delegate()->current_time();
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
dds::domain::qos::DomainParticipantQos TDomainParticipant<DELEGATE>::default_participant_qos()
|
||||
{
|
||||
return DELEGATE::default_participant_qos();
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
void TDomainParticipant<DELEGATE>::default_participant_qos(const ::dds::domain::qos::DomainParticipantQos& qos)
|
||||
{
|
||||
DELEGATE::default_participant_qos(qos);
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
dds::pub::qos::PublisherQos TDomainParticipant<DELEGATE>::default_publisher_qos() const
|
||||
{
|
||||
return this->delegate()->default_publisher_qos();
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
TDomainParticipant<DELEGATE>& TDomainParticipant<DELEGATE>::default_publisher_qos(
|
||||
const ::dds::pub::qos::PublisherQos& qos)
|
||||
{
|
||||
this->delegate()->default_publisher_qos(qos);
|
||||
return *this;
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
dds::sub::qos::SubscriberQos TDomainParticipant<DELEGATE>::default_subscriber_qos() const
|
||||
{
|
||||
return this->delegate()->default_subscriber_qos();
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
TDomainParticipant<DELEGATE>& TDomainParticipant<DELEGATE>::default_subscriber_qos(
|
||||
const ::dds::sub::qos::SubscriberQos& qos)
|
||||
{
|
||||
this->delegate()->default_subscriber_qos(qos);
|
||||
return *this;
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
dds::topic::qos::TopicQos TDomainParticipant<DELEGATE>::default_topic_qos() const
|
||||
{
|
||||
return this->delegate()->default_topic_qos();
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
TDomainParticipant<DELEGATE>& TDomainParticipant<DELEGATE>::default_topic_qos(const dds::topic::qos::TopicQos& qos)
|
||||
{
|
||||
this->delegate()->default_topic_qos(qos);
|
||||
return *this;
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
TDomainParticipant<DELEGATE>& TDomainParticipant<DELEGATE>::operator << (const dds::domain::qos::DomainParticipantQos& qos)
|
||||
{
|
||||
this->qos(qos);
|
||||
return *this;
|
||||
}
|
||||
|
||||
template <typename DELEGATE>
|
||||
const TDomainParticipant<DELEGATE>& TDomainParticipant<DELEGATE>::operator >> (dds::domain::qos::DomainParticipantQos& qos) const
|
||||
{
|
||||
qos = this->qos();
|
||||
return *this;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
// End of implementation
|
||||
|
||||
#endif /* CYCLONEDDS_DDS_DOMAIN_TDOMAINPARTICIPANT_IMPL_HPP_ */
|
17
unitree_SDK/include/ddscxx/dds/domain/detail/ddsdomain.hpp
Normal file
17
unitree_SDK/include/ddscxx/dds/domain/detail/ddsdomain.hpp
Normal file
@@ -0,0 +1,17 @@
|
||||
/*
|
||||
* Copyright(c) 2006 to 2020 ZettaScale Technology and others
|
||||
*
|
||||
* This program and the accompanying materials are made available under the
|
||||
* terms of the Eclipse Public License v. 2.0 which is available at
|
||||
* http://www.eclipse.org/legal/epl-2.0, or the Eclipse Distribution License
|
||||
* v. 1.0 which is available at
|
||||
* http://www.eclipse.org/org/documents/edl-v10.php.
|
||||
*
|
||||
* SPDX-License-Identifier: EPL-2.0 OR BSD-3-Clause
|
||||
*/
|
||||
#ifndef OMG_DDS_DOMAIN_PACKAGE_DETAIL_INCLUDE_HPP_
|
||||
#define OMG_DDS_DOMAIN_PACKAGE_DETAIL_INCLUDE_HPP_
|
||||
|
||||
/* Nothing to 'post' include. */
|
||||
|
||||
#endif /* OMG_DDS_DOMAIN_PACKAGE_DETAIL_INCLUDE_HPP_ */
|
Reference in New Issue
Block a user