pub struct Actor;Expand description
Chaos Actor
Implementations§
Source§impl Actor
impl Actor
pub fn send<BS, RT>(
rt: &mut RT,
arg: SendArgs,
) -> Result<SendReturn, ActorError>where
BS: Blockstore,
RT: Runtime<BS>,
Sourcepub fn constructor<BS, RT>(_rt: &mut RT)where
BS: Blockstore,
RT: Runtime<BS>,
pub fn constructor<BS, RT>(_rt: &mut RT)where
BS: Blockstore,
RT: Runtime<BS>,
Constructor for Account actor
Sourcepub fn caller_validation<BS, RT>(
rt: &mut RT,
args: CallerValidationArgs,
) -> Result<(), ActorError>where
BS: Blockstore,
RT: Runtime<BS>,
pub fn caller_validation<BS, RT>(
rt: &mut RT,
args: CallerValidationArgs,
) -> Result<(), ActorError>where
BS: Blockstore,
RT: Runtime<BS>,
CallerValidation violates VM call validation constraints.
CALLER_VALIDATION_BRANCH_NONE performs no validation. CALLER_VALIDATION_BRANCH_TWICE validates twice. CALLER_VALIDATION_BRANCH_IS_ADDRESS validates against an empty caller address set. CALLER_VALIDATION_BRANCH_IS_TYPE validates against an empty caller type set.
pub fn create_actor<BS, RT>(
rt: &mut RT,
arg: CreateActorArgs,
) -> Result<(), ActorError>where
BS: Blockstore,
RT: Runtime<BS>,
Sourcepub fn resolve_address<BS, RT>(
rt: &mut RT,
args: Address,
) -> Result<ResolveAddressResponse, ActorError>where
BS: Blockstore,
RT: Runtime<BS>,
pub fn resolve_address<BS, RT>(
rt: &mut RT,
args: Address,
) -> Result<ResolveAddressResponse, ActorError>where
BS: Blockstore,
RT: Runtime<BS>,
Resolves address, and returns the resolved address (defaulting to 0 ID) and success boolean.
pub fn delete_actor<BS, RT>(
rt: &mut RT,
beneficiary: Address,
) -> Result<(), ActorError>where
BS: Blockstore,
RT: Runtime<BS>,
pub fn mutate_state<BS, RT>(
rt: &mut RT,
arg: MutateStateArgs,
) -> Result<(), ActorError>where
BS: Blockstore,
RT: Runtime<BS>,
pub fn abort_with(arg: AbortWithArgs) -> Result<(), ActorError>
pub fn inspect_runtime<BS, RT>(
rt: &mut RT,
) -> Result<InspectRuntimeReturn, ActorError>where
BS: Blockstore,
RT: Runtime<BS>,
Trait Implementations§
Source§impl ActorCode for Actor
impl ActorCode for Actor
Source§fn invoke_method<BS, RT>(
rt: &mut RT,
method: MethodNum,
params: &RawBytes,
) -> Result<RawBytes, ActorError>where
BS: Blockstore,
RT: Runtime<BS>,
fn invoke_method<BS, RT>(
rt: &mut RT,
method: MethodNum,
params: &RawBytes,
) -> Result<RawBytes, ActorError>where
BS: Blockstore,
RT: Runtime<BS>,
Invokes method with runtime on the actor’s code. Method number will match one
defined by the Actor, and parameters will be serialized and used in execution
Auto Trait Implementations§
impl Freeze for Actor
impl RefUnwindSafe for Actor
impl Send for Actor
impl Sync for Actor
impl Unpin for Actor
impl UnwindSafe for Actor
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> 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