Skip to main content

zerodds_ros2_rmw/
lib.rs

1// SPDX-License-Identifier: Apache-2.0
2// Copyright 2026 ZeroDDS Contributors
3
4//! ROS 2 RMW Bridge Layer.
5//!
6//! Crate `zerodds-ros2-rmw`. Safety classification: **STANDARD**.
7//! Specs: `docs/standards/cache/ros2/rep-{2003,2004,2005,2007,2008,
8//! 2009}.html` (ROS Enhancement Proposals).
9//!
10//! # Scope
11//!
12//! Wir implementieren die ROS-2-DDS-Mapping-Conventions als pure-Rust
13//! no_std+alloc Library:
14//!
15//! * **Topic-Name-Mangling** (de-facto-Standard aus `rmw_dds_common`):
16//!   ROS 2 logical names werden mit Prefix-Code (`rt/`, `rq/`, `rr/`,
17//!   `rs/`) auf DDS-Topic-Namen gemapped.
18//! * **REP-2003 QoS Settings** — Map-/Sensor-Data-QoS-Profiles
19//!   (Reliable+TransientLocal fuer Maps; BestEffort+Volatile fuer
20//!   Sensor-Data).
21//! * **REP-2004 Package Quality Categories** — Q1-Q5-Klassifikation.
22//! * **Standard RMW QoS Profiles** — DEFAULT/SENSOR_DATA/PARAMETERS/
23//!   SERVICES_DEFAULT/PARAMETER_EVENTS/SYSTEM_DEFAULT.
24//!
25//! # Was nicht abgedeckt ist
26//!
27//! * **REP-2005 Common Packages** — Informational.
28//! * **REP-2007 Type Adaptation** — Compile-Time-Feature in C++/Python
29//!   `rclcpp`/`rclpy`; nicht Wire-Layer.
30//! * **REP-2008 Hardware Acceleration** — Driver-Layer.
31//! * **REP-2009 Type Negotiation** — Compile-Time-Feature.
32//! * **`rmw`-C-API** — die Rust-Crate liefert Mapping-Konstanten und
33//!   Profile; das eigentliche `rmw_zerodds`-C-FFI-Crate ist eigener
34//!   Sprint.
35
36#![forbid(unsafe_code)]
37#![warn(missing_docs)]
38
39extern crate alloc;
40
41pub mod action;
42pub mod ffi_api;
43pub mod json_log;
44pub mod msg_to_idl;
45pub mod qos_profiles;
46pub mod quality;
47pub mod rmw_qos_mapping;
48pub mod service;
49pub mod topic_mangling;
50pub mod type_mapping;
51
52pub use ffi_api::{
53    RMW_IMPLEMENTATION_IDENTIFIER, RmwNode, RmwRet, check_rmw_identifier, map_to_rmw_ret,
54};
55pub use qos_profiles::{Durability, History, QosProfile, Reliability, profiles};
56pub use quality::QualityLevel;
57pub use rmw_qos_mapping::{
58    RmwDurability, RmwHistory, RmwQosProfile, RmwReliability, dds_to_rmw, rmw_to_dds,
59};
60pub use topic_mangling::{
61    NameMangleError, RosKind, demangle_topic_name, is_ros_topic, mangle_topic_name,
62};
63pub use type_mapping::{RosBuiltinType, RosNamespace, RosTypeRef};