pub struct TypeHash { /* private fields */ }Expand description
A parsed ROS 2 type hash in the RIHS01 scheme (REP-2011).
The string form is RIHS01_ followed by 64 lowercase hex digits, the version prefix plus a
SHA-256 digest of the type’s description.
§Examples
use pamoja_ros2::typehash::TypeHash;
// The published hash of std_msgs/msg/String round-trips through parse and display.
let text = "RIHS01_df668c740482bbd48fb39d76a70dfd4bd59db1288021743503259e948f6b1a18";
let hash = TypeHash::parse(text).unwrap();
assert_eq!(hash.to_string(), text);Implementations§
Trait Implementations§
impl Copy for TypeHash
impl Eq for TypeHash
impl StructuralPartialEq for TypeHash
Auto Trait Implementations§
impl Freeze for TypeHash
impl RefUnwindSafe for TypeHash
impl Send for TypeHash
impl Sync for TypeHash
impl Unpin for TypeHash
impl UnsafeUnpin for TypeHash
impl UnwindSafe for TypeHash
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more