Struct recrypt::api::Plaintext [−]
pub struct Plaintext { /* fields omitted */ }
Not hashed, not encrypted Fp12Elem See DecryptedSymmetricKey and EncryptedMessage
Methods
impl Plaintext
impl Plaintext
pub fn new(bytes: [u8; 384]) -> Plaintext
pub fn new(bytes: [u8; 384]) -> Plaintext
Construct a Plaintext from raw bytes
pub fn new_from_slice(bytes: &[u8]) -> Result<Plaintext, ApiErr>
pub fn new_from_slice(bytes: &[u8]) -> Result<Plaintext, ApiErr>
construct $t from byte slice. Input slice must be exactly the correct length for the type.
Returns
Ok($t) or Err($ApiError::InputWrongSize]
pub fn bytes(&self) -> &[u8; 384]
pub fn bytes(&self) -> &[u8; 384]
Trait Implementations
impl Clone for Plaintext
impl Clone for Plaintext
fn clone(&self) -> Plaintext
fn clone(&self) -> Plaintext
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0
[src]Performs copy-assignment from source
. Read more
impl Copy for Plaintext
impl Copy for Plaintext
impl Debug for Plaintext
impl Debug for Plaintext
fn fmt(&self, formatter: &mut Formatter) -> Result
fn fmt(&self, formatter: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl PartialEq for Plaintext
impl PartialEq for Plaintext