pub trait SourceAdmission<RootEvent, Source, Input>: Sendwhere
RootEvent: EventIngress<Source, Input>,{
// Required method
fn admit_source(
&mut self,
input: Input,
) -> impl Future<Output = Result<(), Input>> + Send;
}Expand description
Bombay ownership port for one exact current-actor system input.
Success transfers the input to the existing actor loop. Closed admission returns the unchanged input to the current lifecycle host.
An event without the exact source ingress cannot implement this port:
ⓘ
struct EventWithoutInput;
struct Owner;
struct Input;
struct Host;
impl behavior::SourceAdmission<EventWithoutInput, Owner, Input> for Host {
async fn admit_source(&mut self, _: Input) -> Result<(), Input> { Ok(()) }
}Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".