#[non_exhaustive]pub struct PicCallContext {
pub operation: &'static str,
pub canister_id: Principal,
pub caller: Principal,
pub method: String,
}Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.operation: &'static str§canister_id: Principal§caller: Principal§method: StringImplementations§
Source§impl PicCallContext
impl PicCallContext
Sourcepub fn new(
operation: &'static str,
canister_id: Principal,
caller: Principal,
method: impl Into<String>,
) -> Self
pub fn new( operation: &'static str, canister_id: Principal, caller: Principal, method: impl Into<String>, ) -> Self
Capture the stable call metadata attached to one call failure.
Sourcepub const fn operation(&self) -> &'static str
pub const fn operation(&self) -> &'static str
Read the PocketIC operation name, such as update_call or query_call.
Sourcepub const fn canister_id(&self) -> Principal
pub const fn canister_id(&self) -> Principal
Read the target canister id.
Trait Implementations§
Source§impl Clone for PicCallContext
impl Clone for PicCallContext
Source§fn clone(&self) -> PicCallContext
fn clone(&self) -> PicCallContext
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PicCallContext
impl Debug for PicCallContext
Source§impl PartialEq for PicCallContext
impl PartialEq for PicCallContext
Source§fn eq(&self, other: &PicCallContext) -> bool
fn eq(&self, other: &PicCallContext) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for PicCallContext
impl StructuralPartialEq for PicCallContext
Auto Trait Implementations§
impl Freeze for PicCallContext
impl RefUnwindSafe for PicCallContext
impl Send for PicCallContext
impl Sync for PicCallContext
impl Unpin for PicCallContext
impl UnsafeUnpin for PicCallContext
impl UnwindSafe for PicCallContext
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.