pub struct AttributeHandle(/* private fields */);Expand description
Handle of a class attribute of the FDD.
Opaque: equality, ordering and hashing work on the encoded bytes. Display prints them in
hexadecimal.
Implementations§
Source§impl AttributeHandle
impl AttributeHandle
Sourcepub fn from_encoded(encoded: impl Into<Bytes>) -> Self
pub fn from_encoded(encoded: impl Into<Bytes>) -> Self
Wraps the encoded form of a handle exactly as an RTI produced it.
Sourcepub fn decode(encoded: &[u8]) -> RtiResult<Self>
pub fn decode(encoded: &[u8]) -> RtiResult<Self>
Reconstitutes a handle that was received as a value, for example inside an attribute or
parameter value (12.2). Fails with CouldNotDecode when there are no bytes at all.
Sourcepub fn encode(&self) -> Bytes
pub fn encode(&self) -> Bytes
The encoded form, ready to be sent as a value to other federates (12.2).
Sourcepub fn encoded_length(&self) -> usize
pub fn encoded_length(&self) -> usize
Number of bytes of the encoded form.
Trait Implementations§
Source§impl AsRef<[u8]> for AttributeHandle
impl AsRef<[u8]> for AttributeHandle
Source§impl Clone for AttributeHandle
impl Clone for AttributeHandle
Source§impl Debug for AttributeHandle
impl Debug for AttributeHandle
Source§impl Display for AttributeHandle
impl Display for AttributeHandle
impl Eq for AttributeHandle
Source§impl Hash for AttributeHandle
impl Hash for AttributeHandle
Source§impl Ord for AttributeHandle
impl Ord for AttributeHandle
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialEq for AttributeHandle
impl PartialEq for AttributeHandle
Source§impl PartialOrd for AttributeHandle
impl PartialOrd for AttributeHandle
impl StructuralPartialEq for AttributeHandle
Auto Trait Implementations§
impl !Freeze for AttributeHandle
impl Forget for AttributeHandle
impl Move for AttributeHandle
impl RefUnwindSafe for AttributeHandle
impl Send for AttributeHandle
impl Sync for AttributeHandle
impl Unpin for AttributeHandle
impl UnsafeUnpin for AttributeHandle
impl UnwindSafe for AttributeHandle
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