pub struct ValueBuffer { /* private fields */ }Expand description
A value represented as in-memory bytes with flexible byteorder.
Implementations§
Source§impl ValueBuffer
impl ValueBuffer
Sourcepub fn empty(ty: Type) -> Self
pub fn empty(ty: Type) -> Self
A value with a count of zero.
The byte order is set to the native byte order of the platform.
Sourcepub fn from_value<T: TiffValue>(value: &T) -> Self
pub fn from_value<T: TiffValue>(value: &T) -> Self
Create a value with native byte order from in-memory data.
pub fn byte_order(&self) -> ByteOrder
pub fn data_type(&self) -> Type
Sourcepub fn as_bytes_mut(&mut self) -> &mut [u8] ⓘ
pub fn as_bytes_mut(&mut self) -> &mut [u8] ⓘ
View the underlying mutable raw bytes of this value.
Sourcepub fn set_byte_order(&mut self, byte_order: ByteOrder)
pub fn set_byte_order(&mut self, byte_order: ByteOrder)
Change the byte order of the value representation.
Auto Trait Implementations§
impl Freeze for ValueBuffer
impl RefUnwindSafe for ValueBuffer
impl Send for ValueBuffer
impl Sync for ValueBuffer
impl Unpin for ValueBuffer
impl UnsafeUnpin for ValueBuffer
impl UnwindSafe for ValueBuffer
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