pub struct LifecycleResource<T> { /* private fields */ }Expand description
A native provider value accompanied by lifecycle hooks registered for it.
Implementations§
Source§impl<T> LifecycleResource<T>
impl<T> LifecycleResource<T>
Sourcepub fn with_infrastructure_hook<H>(self, owner: &'static str, hook: H) -> Selfwhere
H: LifecycleHook + 'static,
pub fn with_infrastructure_hook<H>(self, owner: &'static str, hook: H) -> Selfwhere
H: LifecycleHook + 'static,
Adds an infrastructure hook owned by the named framework component.
Sourcepub fn with_application_hook<H>(self, hook: H) -> Selfwhere
H: LifecycleHook + 'static,
pub fn with_application_hook<H>(self, hook: H) -> Selfwhere
H: LifecycleHook + 'static,
Adds an application hook after previously authored registrations.
Auto Trait Implementations§
impl<T> !RefUnwindSafe for LifecycleResource<T>
impl<T> !UnwindSafe for LifecycleResource<T>
impl<T> Forget for LifecycleResource<T>
impl<T> Freeze for LifecycleResource<T>where
T: Freeze,
impl<T> Move for LifecycleResource<T>
impl<T> Send for LifecycleResource<T>where
T: Send,
impl<T> Sync for LifecycleResource<T>where
T: Sync,
impl<T> Unpin for LifecycleResource<T>where
T: Unpin,
impl<T> UnsafeUnpin for LifecycleResource<T>where
T: UnsafeUnpin,
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