pub unsafe trait App<'d>: Sized + Layout<'d> {
const ROUTES: Routes;
const DISPATCH_ROUTES: Routes = Self::ROUTES;
const WAKE_ROUTES: Routes = settings::Routes::EMPTY;
const COORDS: usize = 0;
const PARK: bool = false;
Show 13 methods
// Provided methods
fn child(_: Pin<&mut Self>) -> Option<Pin<&mut impl App<'d>>> { ... }
fn census(_: Pin<&Self>, counts: &mut Census) -> Result<(), Overflow> { ... }
unsafe fn sweep<'app, 'driver, 'turn>(
app: Pin<&'app mut Self>,
sweep: &mut Sweep<'driver, 'turn, 'd, impl Report<Event = <Arena as Drain>::Reported>>,
)
where 'd: 'driver + 'turn { ... }
unsafe fn park<'app, 'driver, 'turn>(
app: Pin<&'app mut Self>,
turn: Turn<'turn, 'd>,
driver: &'driver mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>,
)
where 'd: 'driver + 'turn { ... }
fn admit(_: Pin<&Self>, needs: &mut Needs) -> Result<(), Claim> { ... }
unsafe fn released(app: Pin<&mut Self>) { ... }
fn install(app: Pin<&mut Self>, install: Install<'_, 'd>) { ... }
unsafe fn activate<'app, 'driver, 'turn>(
_: Pin<&'app mut Self>,
_: Erased<'d, Any>,
_: Turn<'turn, 'd>,
_: &'driver mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>,
) -> ControlFlow<()>
where 'd: 'driver + 'turn { ... }
fn has_receiver(_: Pin<&Self>, route: Route) -> bool { ... }
fn dispatch<'event>(
_: Pin<&mut Self>,
event: Dispatch<'event, 'd, Self::Scope>,
_: Turn<'_, 'd>,
_: &mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>,
) -> ControlFlow<Dispatch<'event, 'd, Self::Scope>> { ... }
fn progress<const STOP: bool>(
_: Pin<&Self>,
_: Progress<'_, '_, 'd>,
_: Option<&mut Waits<'d>>,
) -> ControlFlow<()> { ... }
fn shutdown(
app: Pin<&mut Self>,
turn: Turn<'_, 'd>,
driver: &mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>,
) { ... }
fn finish(
app: Pin<&mut Self>,
install: Install<'_, 'd>,
finish: &mut Finish<'_, 'd, impl Report<Event = <Arena as Drain>::Reported>>,
) { ... }
}Expand description
§Safety
Visit each unchanged pinned owner once, admitting its fixed Scope route and operation authority. Shutdown retains clients; finish destroys dependents first. Unit plans park; Flat preserves census order.
Required Associated Constants§
Provided Associated Constants§
Sourceconst DISPATCH_ROUTES: Routes = Self::ROUTES
const DISPATCH_ROUTES: Routes = Self::ROUTES
Routes on which a nested application may observe a completion.
Sourceconst WAKE_ROUTES: Routes = settings::Routes::EMPTY
const WAKE_ROUTES: Routes = settings::Routes::EMPTY
Routes whose installed owners may receive activation.
const PARK: bool = false
Provided Methods§
Sourcefn child(_: Pin<&mut Self>) -> Option<Pin<&mut impl App<'d>>>
fn child(_: Pin<&mut Self>) -> Option<Pin<&mut impl App<'d>>>
The unchanged pinned child that receives this owner’s default lifecycle traversal.
fn census(_: Pin<&Self>, counts: &mut Census) -> Result<(), Overflow>
Sourceunsafe fn sweep<'app, 'driver, 'turn>(
app: Pin<&'app mut Self>,
sweep: &mut Sweep<'driver, 'turn, 'd, impl Report<Event = <Arena as Drain>::Reported>>,
)where
'd: 'driver + 'turn,
unsafe fn sweep<'app, 'driver, 'turn>(
app: Pin<&'app mut Self>,
sweep: &mut Sweep<'driver, 'turn, 'd, impl Report<Event = <Arena as Drain>::Reported>>,
)where
'd: 'driver + 'turn,
§Safety
Traverse the same admitted pinned owners in their census order.
Sourceunsafe fn park<'app, 'driver, 'turn>(
app: Pin<&'app mut Self>,
turn: Turn<'turn, 'd>,
driver: &'driver mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>,
)where
'd: 'driver + 'turn,
unsafe fn park<'app, 'driver, 'turn>(
app: Pin<&'app mut Self>,
turn: Turn<'turn, 'd>,
driver: &'driver mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>,
)where
'd: 'driver + 'turn,
§Safety
The exact pinned root is installed and admitted. Run this leaf’s work or this aggregate’s own coordinator with the same driver and turn.
Sourcefn admit(_: Pin<&Self>, needs: &mut Needs) -> Result<(), Claim>
fn admit(_: Pin<&Self>, needs: &mut Needs) -> Result<(), Claim>
Accumulates the routes of the owners actually present in this pinned root.
Sourceunsafe fn released(app: Pin<&mut Self>)
unsafe fn released(app: Pin<&mut Self>)
§Safety
All external clients of this exact pinned owner have ended.
fn install(app: Pin<&mut Self>, install: Install<'_, 'd>)
Sourceunsafe fn activate<'app, 'driver, 'turn>(
_: Pin<&'app mut Self>,
_: Erased<'d, Any>,
_: Turn<'turn, 'd>,
_: &'driver mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>,
) -> ControlFlow<()>where
'd: 'driver + 'turn,
unsafe fn activate<'app, 'driver, 'turn>(
_: Pin<&'app mut Self>,
_: Erased<'d, Any>,
_: Turn<'turn, 'd>,
_: &'driver mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>,
) -> ControlFlow<()>where
'd: 'driver + 'turn,
§Safety
Use this installed root, driver and turn with a target admitted by WAKE_ROUTES. Break only when a present owner consumed this activation.
Sourcefn has_receiver(_: Pin<&Self>, route: Route) -> bool
fn has_receiver(_: Pin<&Self>, route: Route) -> bool
Resolves overlapping candidate routes against the receivers actually installed in this root.
Sourcefn dispatch<'event>(
_: Pin<&mut Self>,
event: Dispatch<'event, 'd, Self::Scope>,
_: Turn<'_, 'd>,
_: &mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>,
) -> ControlFlow<Dispatch<'event, 'd, Self::Scope>>
fn dispatch<'event>( _: Pin<&mut Self>, event: Dispatch<'event, 'd, Self::Scope>, _: Turn<'_, 'd>, _: &mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>, ) -> ControlFlow<Dispatch<'event, 'd, Self::Scope>>
A selected receiver consumes the completion or returns it to the driver.
Sourcefn progress<const STOP: bool>(
_: Pin<&Self>,
_: Progress<'_, '_, 'd>,
_: Option<&mut Waits<'d>>,
) -> ControlFlow<()>
fn progress<const STOP: bool>( _: Pin<&Self>, _: Progress<'_, '_, 'd>, _: Option<&mut Waits<'d>>, ) -> ControlFlow<()>
Reports waits into the same traversal until an owner can run immediately.
fn shutdown( app: Pin<&mut Self>, turn: Turn<'_, 'd>, driver: &mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>, )
fn finish( app: Pin<&mut Self>, install: Install<'_, 'd>, finish: &mut Finish<'_, 'd, impl Report<Event = <Arena as Drain>::Reported>>, )
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementations on Foreign Types§
Implementors§
Source§impl<'app, 'd, H, T> App<'d> for Bound<'app, 'd, H, T>
SAFETY: each lifecycle operation visits all declared owners once,
through the same pinned projections and presence in the declared lifecycle order.
The root stays pinned through finish and retains each operation’s authority.
impl<'app, 'd, H, T> App<'d> for Bound<'app, 'd, H, T>
SAFETY: each lifecycle operation visits all declared owners once, through the same pinned projections and presence in the declared lifecycle order. The root stays pinned through finish and retains each operation’s authority.