pub struct RegisteredPullConsumer { /* private fields */ }Expand description
A consumer registration that has been recorded in a
crate::kernel::subcontext::SubcontextBuilder.
Wraps an Arc<dyn PullConsumer> so consumers can be cheaply
shared between the artifact and the spawned kernel without
trait-object cloning. The host’s fixture adapter owns the seal
step; this type only records the consumer for later
inspection.
Implementations§
Source§impl RegisteredPullConsumer
impl RegisteredPullConsumer
Sourcepub fn new(consumer: Arc<dyn PullConsumer>) -> Self
pub fn new(consumer: Arc<dyn PullConsumer>) -> Self
A registered consumer wrapping consumer.
Sourcepub fn names(&self) -> &[String]
pub fn names(&self) -> &[String]
Inspect the names this consumer requested. Used by the activity-side adapter at seal time and by Phase 1 tests to verify the registration round-trip.
Sourcepub fn as_dyn(&self) -> &dyn PullConsumer
pub fn as_dyn(&self) -> &dyn PullConsumer
Borrow the underlying trait object — the activity-side adapter uses this to dispatch to consumer-specific configuration once it has the kernel program in hand.
Trait Implementations§
Source§impl Clone for RegisteredPullConsumer
impl Clone for RegisteredPullConsumer
Source§fn clone(&self) -> RegisteredPullConsumer
fn clone(&self) -> RegisteredPullConsumer
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl !RefUnwindSafe for RegisteredPullConsumer
impl !UnwindSafe for RegisteredPullConsumer
impl Freeze for RegisteredPullConsumer
impl Send for RegisteredPullConsumer
impl Sync for RegisteredPullConsumer
impl Unpin for RegisteredPullConsumer
impl UnsafeUnpin for RegisteredPullConsumer
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
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> 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> 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