Skip to main content

Module prelude

Module prelude 

Source
Expand description

Prelude module for convenient imports

Import everything you need with a single statement:

use nros::prelude::*;

Re-exports§

pub use crate::NodeExecutorRuntime;
pub use crate::SourceMetadataExport;
pub use crate::ActionTag;
pub use crate::Callback;
pub use crate::CallbackEffectKind;
pub use crate::CallbackEffects;
pub use crate::DeclaredNode;
pub use crate::DeclaredNodeRuntime;
pub use crate::EntityKind;
pub use crate::MetadataRecorder;
pub use crate::Node;
pub use crate::NodeActionClient;
pub use crate::NodeActionServer;
pub use crate::NodeContext;
pub use crate::NodeDeclError;
pub use crate::NodeOptions;
pub use crate::NodeParameter;
pub use crate::NodePublisher;
pub use crate::NodeResult;
pub use crate::NodeRuntime;
pub use crate::NodeRuntimeAdapter;
pub use crate::NodeServiceClient;
pub use crate::NodeServiceServer;
pub use crate::NodeSubscription;
pub use crate::NodeTimer;
pub use crate::ParameterDefault;
pub use crate::RuntimeNodeRecord;
pub use crate::ServiceTag;
pub use crate::SourceLocationMetadata;
pub use crate::SourceNameKind;
pub use crate::SubscriptionTag;
pub use crate::node;
pub use crate::record_node_metadata;
pub use crate::register_node;

Macros§

node
Export a Rust type implementing nros::Node as the package node.

Structs§

CdrReader
CDR reader for deserialization
CdrWriter
CDR writer for serialization.
Clock
A clock for querying time
Duration
ROS Duration representation
EmbeddedPublisher
Typed publisher handle.
EmbeddedServiceClient
Typed service client handle with internal buffers.
Executor
ExecutorConfig
Configuration for opening an embedded executor session.
FeedbackStream
A stream of feedback messages from an action server.
GoalId
Unique identifier for a goal
GoalInfo
Information about a goal
GoalStatusStamped
Goal status with associated goal info
GuardConditionHandle
Handle for triggering a guard condition from outside the executor.
HandleId
Opaque handle identifier returned by registration methods.
HandleSet
A set of handle IDs, represented as a bitset.
LifecyclePollingNode
Standalone lifecycle state machine for no_std environments.
Logger
A logger associated with a ROS node
MandatoryParameter
A parameter that must always have a value
MessageInfo
Metadata about a received message
NodeConfig
Node configuration
NodeHandle
Backend-agnostic node — borrows the session to create typed entities.
OptionalParameter
A parameter that may or may not have a value
ParameterBuilder
Builder for declaring a typed parameter
ParameterServer
Parameter server with static storage
Promise
A pending reply from a non-blocking service or action call.
PublisherHandle
Handle to a publisher
PublisherOptions
Options for creating a publisher
QosSettings
Full DDS-shaped QoS profile. Matches the field set of upstream rmw_qos_profile_t.
ReadOnlyParameter
A parameter whose value cannot be changed after declaration
SpinOnceResult
Result of a single spin iteration
SpinOptions
Options controlling blocking spin behavior.
SpinPeriodPollingResult
Result from a single period of polling execution (no_std compatible).
SpinPeriodResult
Result from a single period with wall-clock measurement (std only).
StandaloneNode
ROS 2 Node for embedded systems
SubscriberHandle
Handle to a subscriber
SubscriberOptions
Options for creating a subscriber
Subscription
Typed subscription handle with internal receive buffer.
Time
ROS Time representation
TimerDuration
Duration type for timer periods
TimerHandle
A handle to a timer stored in a node
TopicInfo
Topic information for pub/sub

Enums§

ClockType
Type of clock to use for time queries
GoalResponse
Goal accept/reject response codes
GoalStatus
Goal status states
InvocationMode
Per-callback invocation mode.
LifecycleError
Error type for lifecycle transitions.
LifecycleState
Lifecycle state (REP-2002)
LifecycleTransition
Lifecycle transition (REP-2002)
NodeError
Error type for generic embedded node operations.
ParameterError
Error type for typed parameter operations
ParameterType
ROS 2 parameter types
ParameterValue
Parameter value container
QosDurabilityPolicy
QoS durability policy
QosHistoryPolicy
QoS history policy
QosReliabilityPolicy
QoS reliability policy
SessionMode
Session mode
TimerMode
Timer mode (repeating, one-shot, or inert)
TransitionResult
Result of a lifecycle transition callback.
TransportError
Transport error types.
Trigger
Executor-level trigger condition.

Traits§

Deserialize
Trait for types that can be deserialized from CDR format
ParameterVariant
Trait for types that can be used as typed parameters
RosAction
Trait for ROS 2 action types
RosMessage
Trait for ROS message types
RosService
Trait for ROS service types
Serialize
Trait for types that can be serialized to CDR format

Type Aliases§

LifecycleCallbackFn
Lifecycle callback function pointer (no_std compatible).
TimerCallbackFn
Timer callback as a bare function pointer (no_std, no heap required).