pub struct Signature { /* private fields */ }
Implementations
sourceimpl Signature
impl Signature
pub fn new(
sign_source: SignatureSource,
sign_key_index: u8,
sign_time: u64,
sign: SignData
) -> Self
pub fn sign(&self) -> &SignData
pub fn as_slice<'a>(&self) -> &'a [u8]ⓘNotable traits for &[u8]impl Read for &[u8]impl Write for &mut [u8]
pub fn is_ref_index(&self) -> bool
pub fn is_object(&self) -> bool
pub fn is_key(&self) -> bool
pub fn sign_source(&self) -> &SignatureSource
pub fn sign_time(&self) -> u64
pub fn sign_key_index(&self) -> u8
pub fn compare_source(&self, other: &Self) -> bool
Trait Implementations
sourceimpl ObjectFormat for Signature
impl ObjectFormat for Signature
fn format_json(&self) -> Value
sourceimpl<'de> RawDecode<'de> for Signature
impl<'de> RawDecode<'de> for Signature
fn raw_decode(buf: &'de [u8]) -> Result<(Self, &'de [u8]), BuckyError>
fn raw_decode_with_option(
buf: &'de [u8],
_opt: &RawDecodeOption
) -> BuckyResult<(Self, &'de [u8])>
sourceimpl RawEncode for Signature
impl RawEncode for Signature
fn raw_measure(
&self,
purpose: &Option<RawEncodePurpose>
) -> Result<usize, BuckyError>
fn raw_encode<'a>(
&self,
buf: &'a mut [u8],
purpose: &Option<RawEncodePurpose>
) -> Result<&'a mut [u8], BuckyError>
fn raw_tail_encode<'a>(
&self,
buf: &'a mut [u8],
purpose: &Option<RawEncodePurpose>
) -> BuckyResult<&'a [u8]>
fn raw_encode_to_buffer(&self) -> BuckyResult<Vec<u8>>
fn raw_hash_value(&self) -> BuckyResult<HashValue>
fn hash_buf(&self, encoded_buf: &[u8]) -> HashValue
fn raw_hash_encode(&self) -> BuckyResult<Vec<u8>>
impl Eq for Signature
impl StructuralEq for Signature
impl StructuralPartialEq for Signature
Auto Trait Implementations
impl RefUnwindSafe for Signature
impl Send for Signature
impl Sync for Signature
impl Unpin for Signature
impl UnwindSafe for Signature
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more