The signal processing engine of a Cell, transforming incoming signals into outputs.
A Receptor
defines how a cell:
- Accepts input signals of type
I
- Transforms them via custom logic
- Produces output signals of type
O
- Propagates results through synapses
Core Concepts:
- Signal Flow: Input → Transformation → Output → Propagation
- Type Safety: Strict input/output signal typing
- Context Awareness: Cell and user context available
- Error Handling: Built-in exception protection
Example:
final doubler = Receptor<Cell, int, int>(
transform: ({cell, signal, user}) => signal * 2,
user: context
);
Type Parameters:
- Implementers
Constructors
-
Receptor.new({SignalTransform<
C, I, O> ? transform, dynamic user}) -
Creates a signal receptor with transformation logic.
constfactory
Properties
Methods
-
call(
{required covariant C cell, required covariant I signal, Set< Cell> ? notified}) → dynamic - Processes a signal through the receptor pipeline.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited