pub struct CallAuthorizationRequest {
pub selector: AuthorizationSelector,
pub inner_hash: Fr,
pub msg_sender: AztecAddress,
pub function_selector: FunctionSelector,
pub args_hash: Fr,
pub args: Vec<Fr>,
}Expand description
An authorization request for a function call, including the full preimage of the data to be signed.
Mirrors TS CallAuthorizationRequest.
Fields§
§selector: AuthorizationSelectorThe selector identifying the authwit request type.
inner_hash: FrThe inner hash of the authwit (poseidon2([msg_sender, selector, args_hash])).
msg_sender: AztecAddressThe address performing the call (msg_sender).
function_selector: FunctionSelectorThe selector of the function being authorized.
args_hash: FrThe hash of the function arguments.
args: Vec<Fr>The raw function arguments as field elements.
Implementations§
Source§impl CallAuthorizationRequest
impl CallAuthorizationRequest
Sourcepub fn new(
selector: AuthorizationSelector,
inner_hash: Fr,
msg_sender: AztecAddress,
function_selector: FunctionSelector,
args_hash: Fr,
args: Vec<Fr>,
) -> CallAuthorizationRequest
pub fn new( selector: AuthorizationSelector, inner_hash: Fr, msg_sender: AztecAddress, function_selector: FunctionSelector, args_hash: Fr, args: Vec<Fr>, ) -> CallAuthorizationRequest
Construct a new CallAuthorizationRequest.
Sourcepub fn selector() -> AuthorizationSelector
pub fn selector() -> AuthorizationSelector
The selector used by upstream Aztec for CallAuthorizationRequest.
Sourcepub fn from_fields(fields: &[Fr]) -> Result<CallAuthorizationRequest, Error>
pub fn from_fields(fields: &[Fr]) -> Result<CallAuthorizationRequest, Error>
Construct from field elements (deserialization from on-chain data).
Expected layout:
[selector, inner_hash, msg_sender, function_selector, args_hash, ...args]
Trait Implementations§
Source§impl Clone for CallAuthorizationRequest
impl Clone for CallAuthorizationRequest
Source§fn clone(&self) -> CallAuthorizationRequest
fn clone(&self) -> CallAuthorizationRequest
Returns a duplicate of the value. Read more
1.0.0 · 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 CallAuthorizationRequest
impl Debug for CallAuthorizationRequest
Source§impl PartialEq for CallAuthorizationRequest
impl PartialEq for CallAuthorizationRequest
impl Eq for CallAuthorizationRequest
impl StructuralPartialEq for CallAuthorizationRequest
Auto Trait Implementations§
impl Freeze for CallAuthorizationRequest
impl RefUnwindSafe for CallAuthorizationRequest
impl Send for CallAuthorizationRequest
impl Sync for CallAuthorizationRequest
impl Unpin for CallAuthorizationRequest
impl UnwindSafe for CallAuthorizationRequest
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,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more