pub struct AccountEntrypointMetaPaymentMethod { /* private fields */ }Expand description
Wraps a FeePaymentMethod so that fee payment is routed through the
account contract’s entrypoint. This enables an account to pay for
its own deployment transaction.
The inner payment method’s execution payload gets wrapped as a call
to the account’s entrypoint() function with the appropriate
fee payment method option.
Implementations§
Source§impl AccountEntrypointMetaPaymentMethod
impl AccountEntrypointMetaPaymentMethod
Sourcepub fn new(
account: Arc<dyn Account>,
inner: Option<Arc<dyn FeePaymentMethod>>,
fee_entrypoint_options: Option<DefaultAccountEntrypointOptions>,
) -> Self
pub fn new( account: Arc<dyn Account>, inner: Option<Arc<dyn FeePaymentMethod>>, fee_entrypoint_options: Option<DefaultAccountEntrypointOptions>, ) -> Self
Create a new meta payment method.
account: The account whose entrypoint will handle fee payment.inner: Optional inner fee payment method. IfNone, assumes the account pays from its existing Fee Juice balance.fee_entrypoint_options: Optional explicit entrypoint options. IfNone, auto-detects based on fee payer and inner calls.
Trait Implementations§
Source§impl FeePaymentMethod for AccountEntrypointMetaPaymentMethod
impl FeePaymentMethod for AccountEntrypointMetaPaymentMethod
Source§fn get_asset<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<AztecAddress, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_asset<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<AztecAddress, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Returns the address of the asset used for fee payment.
For fee juice methods, this is the FeeJuice protocol contract address.
Source§fn get_fee_payer<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<AztecAddress, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_fee_payer<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<AztecAddress, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Returns the address of the entity paying the fee.
Source§fn get_fee_execution_payload<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<ExecutionPayload, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_fee_execution_payload<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<ExecutionPayload, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Builds an
ExecutionPayload containing the function calls and
auth witnesses needed to pay the transaction fee.Auto Trait Implementations§
impl Freeze for AccountEntrypointMetaPaymentMethod
impl !RefUnwindSafe for AccountEntrypointMetaPaymentMethod
impl Send for AccountEntrypointMetaPaymentMethod
impl Sync for AccountEntrypointMetaPaymentMethod
impl Unpin for AccountEntrypointMetaPaymentMethod
impl !UnwindSafe for AccountEntrypointMetaPaymentMethod
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
§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