Skip to main content

Crate zerodds_types

Crate zerodds_types 

Source
Expand description

Crate zerodds-types. Safety classification: SAFE.

OMG XTypes 1.3 Type-System — TypeIdentifier, TypeObject, Compatibility. Pure-Rust no_std + alloc, forbid(unsafe_code).

§Spec

  • OMG XTypes 1.3 §7.3.1 (TypeIdentifier), §7.3.4 (TypeIdentifier-Union)
  • OMG XTypes 1.3 §7.3.4 (Minimal + Complete TypeObject)
  • OMG XTypes 1.3 §7.3.5 (TypeInformation + Dependencies)
  • OMG XTypes 1.3 §7.3.6 (TypeLookup Service IDL)
  • OMG XTypes 1.3 §7.2.4 (assignability + compatibility rules)
  • OMG XTypes 1.3 §7.6.3 (DynamicType ↔ TypeObject Bridge)
  • OMG XTypes 1.3 §7.6.8 (KeyHash + EquivalenceHash via MD5)
  • OMG DDS 1.4 §2.2.3 (TypeConsistencyEnforcement QoS-Policy)

§Layer position

Layer 1 — primitives. Direct dependents: zerodds-discovery, zerodds-dcps, zerodds-idl, zerodds-rpc, zerodds-xml. Architecture + RFC: docs/rfcs/0004-xtypes-integration.md.

§Public-API modules

  • type_identifier — TypeIdentifier union (§7.3.4.2).
  • type_object — minimal + complete TypeObject (§7.3.4).
  • type_information — TypeInformation + dependencies (§7.3.5).
  • type_lookup — getTypes / getTypeDependencies IDL (§7.3.6).
  • builder — programmatic builder for all kinds.
  • hash — MD5 → 14-byte EquivalenceHash (§7.3.1.2.1).
  • resolve — TypeRegistry + alias resolution + DoS caps.
  • assignability — type-compatibility rules (§7.2.4).
  • type_matcher — writer↔reader matching with TCE policy (§7.6.3.7 + §7.2.4).
  • qos — TypeConsistencyEnforcement + DataRepresentation (DDS 1.4 §2.2.3).
  • dynamic — DynamicType / DynamicData reflection API (§7.5) incl. DynamicType ↔ TypeObject bridge (§7.6.3).

§Wiring status

assignability and type_matcher are public API for end-user code that does its own type-compatibility checks outside the DDS discovery pipeline (e.g. bridge implementations, custom schema registries). The ZeroDDS discovery pipeline currently matches by type_name (DDS 1.4 §2.2.3 default path); full XTypes 1.3 §7.6 TypeIdentifier-aware discovery is its own cross-layer architecture epic (TypeIdentifier constants in codegen + SEDP propagation + TypeRegistry shared state).

Re-exports§

pub use error::TypeCodecError;
pub use hash::compute_complete_hash;
pub use hash::compute_hash;
pub use hash::compute_minimal_hash;
pub use hash::to_hashed_type_identifier;
pub use type_identifier::EquivalenceHash;
pub use type_identifier::EquivalenceKind;
pub use type_identifier::PlainCollectionHeader;
pub use type_identifier::PrimitiveKind;
pub use type_identifier::StronglyConnectedComponentId;
pub use type_identifier::TypeIdentifier;
pub use type_information::TypeIdentifierWithDependencies;
pub use type_information::TypeIdentifierWithSize;
pub use type_information::TypeInformation;
pub use type_object::CompleteTypeObject;
pub use type_object::MinimalTypeObject;
pub use type_object::TypeObject;

Modules§

assignability
Type-Assignability (XTypes 1.3 §7.2.4.1).
builder
Programmatic builder for TypeObjects.
dynamic
XTypes 1.3 §7.5 DynamicType-API.
error
Error types for zerodds-types.
hash
TypeIdentifier hash computation (XTypes 1.3 §7.3.1.2).
qos
XTypes-related QoS policies (T17, T18).
resolve
Type-Resolution + Recursion-Guards (XTypes §7.3.4.5, §7.3.4.9).
type_identifier
XTypes 1.3 TypeIdentifier (Spec §7.3.4.2).
type_information
TypeInformation (XTypes 1.3 §7.6.3.2.2) — wrapper for the discovery of strongly-hashed TypeObjects incl. transitive dependencies.
type_lookup
TypeLookup Service IDL (XTypes 1.3 §7.6.3.3).
type_matcher
Writer↔Reader Type-Matching (XTypes §7.2.4 + §7.6.3.7).
type_object
TypeObject (XTypes 1.3 §7.3.4.4).