pub enum OpDispatch {
Stateless(StatelessInvokeFn),
Atomic {
component_ref: ComponentRef,
dispatch_fn: ProtocolDispatchFn,
},
FunctionCall {
target: FunctionKey,
input_rename: Rc<[(String, String)]>,
output_rename: Rc<[(String, String)]>,
},
Unresolved,
}Expand description
Per-OpRef dispatch decision, pre-stamped at install time by
Engine::resolve_dispatch. Runtime invoke is one indirect probe
against GraphSlot.op_dispatch[idx]. Four variants:
Stateless- framework syscall.Atomic- bound runtime’sdispatch_atomic.FunctionCall- splice into another installed function’s body via sharedOpRefs, with input/output rename for call-frame semantics. Seedocs/ENGINE.md§8.4.Unresolved- sentinel for nodes whose dispatch couldn’t be resolved at install. Build fails if any survive.
Variants§
Stateless(StatelessInvokeFn)
Framework syscall.
Atomic
Bound runtime impl, routed via components[component_ref].
dispatch_fn is the install-time-stamped downcast closure
from Engine::role_dispatchers[component_type_id]. Runtime
invoke calls the closure directly; resolve_dispatch only
stamps Atomic when the closure is available, otherwise it
stamps Unresolved. Test fixtures that bypass install
stamp the closure manually via bind_slot_id +
register_<role>_dispatcher before resolve_dispatch.
Fields
component_ref: ComponentRefComponentRef of the bound impl.
dispatch_fn: ProtocolDispatchFnPre-stamped downcast closure that calls the concrete
<Role>Runtime::dispatch_atomic on the bound component.
FunctionCall
Function-call to another installed function. target keys
into engine.graphs (the symbol table); input_rename /
output_rename map caller-side ↔ formal value names.
Fields
target: FunctionKey(domain, name, overload) of the called function.
Unresolved
Sentinel for unresolved dispatch - set by from_function
before resolve, replaced by resolve_dispatch. Build fails if
any survive past resolution.
Trait Implementations§
Source§impl Clone for OpDispatch
impl Clone for OpDispatch
Source§fn clone(&self) -> OpDispatch
fn clone(&self) -> OpDispatch
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl !Send for OpDispatch
impl !Sync for OpDispatch
impl Freeze for OpDispatch
impl RefUnwindSafe for OpDispatch
impl Unpin for OpDispatch
impl UnsafeUnpin for OpDispatch
impl UnwindSafe for OpDispatch
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request