Trait ascon_aead::Buffer [−][src]
pub trait Buffer: AsRef<[u8]> + AsMut<[u8]> { pub fn extend_from_slice(&mut self, other: &[u8]) -> Result<(), Error>; pub fn truncate(&mut self, len: usize); pub fn len(&self) -> usize { ... } pub fn is_empty(&self) -> bool { ... } }
In-place encryption/decryption byte buffers.
This trait defines the set of methods needed to support in-place operations
on a Vec
-like data type.
Required methods
pub fn extend_from_slice(&mut self, other: &[u8]) -> Result<(), Error>
[src]
Extend this buffer from the given slice
pub fn truncate(&mut self, len: usize)
[src]
Truncate this buffer to the given size
Provided methods
pub fn len(&self) -> usize
[src]
Get the length of the buffer
pub fn is_empty(&self) -> bool
[src]
Is the buffer empty?