Crate appliance[][src]

A lightweight actor model inspired framework to build customizable components with message-based intercommunications.

Structs

Appliance

A stateful entity that only allows to interact with via sending messages.

Descriptor

Appliance descriptor is a cloneable object which allows to send messages to the appliance.

Enums

Error

An error describing appliance failures.

Statics

DEFAULT_EXECUTOR

A default executor. It runs on per-core threads and is fair in terms of task priorities.

Traits

HandledBy

A dual trait for Handler. For any type of messages M and any type of handlers H, if impl Handler<M> for H, then impl HandledBy<H> for M. I.e. we can either ask “which messages can be handled by this appliance” or “which appliances can handle this message”, and the answers to these questions are dual. The trait HandledBy answers the second question.

Handler

A trait which must be implemented for all appliances which are intended to receive messages of type M. One appliance can handle multiple message types.

Message

Message must be implemented for any type which is intended for sending to appliances.

Type Definitions

Executor

An async executor with a customized execution dedication per task.