Skip to main content

remote

Attribute Macro remote 

Source
#[remote]
Expand description

Attribute macro applies to the impl Actor for MyActor { ... } block, which overrides the Actor::type_erased_recipient_fn used by acktor-ipc with a custom implementation that converts Address<Self> to Recipient<RemoteMessage> first and then erases the type.

See the documentation of Actor::type_erased_recipient_fn for more details.

§Example

use acktor_derive::remote;

#[remote]
impl Actor for MyActor {
    type Error = anyhow::Error;
    type Context = Context<Self>;
}