pub struct PolyesterSmartAccount {
pub environment: PolyesterChainEnvironment,
pub salt_nonce: u64,
pub address: String,
pub owner_address: String,
pub initializer: Vec<u8>,
/* private fields */
}Expand description
Owner-key smart account: derive Safe, build/sign/submit Funding UserOps.
Fields§
§environment: PolyesterChainEnvironment§salt_nonce: u64§address: String§owner_address: String§initializer: Vec<u8>Safe setup initializer used for CREATE2 prediction / undeployed initCode.
Implementations§
Source§impl PolyesterSmartAccount
impl PolyesterSmartAccount
pub fn new( owner_private_key: &str, environment: Option<PolyesterChainEnvironment>, salt_nonce: u64, timeout: Duration, ) -> Result<Self>
pub async fn is_deployed(&self) -> Result<bool>
Sourcepub async fn get_nonce(&self, key: Option<u128>) -> Result<U256>
pub async fn get_nonce(&self, key: Option<u128>) -> Result<U256>
Return the next EntryPoint nonce.
Matches viem/permissionless: when key is None, use a fresh
timestamp-based nonce key (Date.now() millis) so ops are not stuck on
key 0 (Polyester’s bundler rejects some key-0 mempool submissions).
pub async fn send_calls( &self, calls: &[ChainCall], wait: bool, receipt_timeout: Duration, ) -> Result<SendCallsResult>
pub async fn wait_for_receipt( &self, user_operation_hash: &str, timeout: Duration, poll_interval: Duration, ) -> Result<UserOperationReceipt>
Auto Trait Implementations§
impl Freeze for PolyesterSmartAccount
impl RefUnwindSafe for PolyesterSmartAccount
impl Send for PolyesterSmartAccount
impl Sync for PolyesterSmartAccount
impl Unpin for PolyesterSmartAccount
impl UnsafeUnpin for PolyesterSmartAccount
impl UnwindSafe for PolyesterSmartAccount
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