[−][src]Struct init_tree::InitializedTree
A collection of all the structures after they've been initialized. Call .take::<MyType>()
on
this to obtain the newly initialized structure.
Methods
impl InitializedTree
[src]
pub fn take<T: 'static>(&mut self) -> Option<T>
[src]
Removes the initialized structure from this tree and returns it.
pub fn take_all(self) -> impl Iterator<Item = (TypeId, Box<dyn Any>)>
[src]
Returns an iterator of all initialized types.
pub fn take_by_type_id(&mut self, t: TypeId) -> Option<Box<dyn Any>>
[src]
Removes the initialized structure from this tree and returns it. Prefer take()
if possible,
but this function is provided in case the type can't be determined at compile time.
pub fn take_cache(&mut self) -> Option<Cache>
[src]
Return the cache from this initialization.
pub fn cache_was_correct(&self) -> bool
[src]
Returns true if the cache loaded in was completely correct.
Trait Implementations
impl Default for InitializedTree
[src]
fn default() -> InitializedTree
[src]
Auto Trait Implementations
impl !RefUnwindSafe for InitializedTree
impl !Send for InitializedTree
impl !Sync for InitializedTree
impl Unpin for InitializedTree
impl !UnwindSafe for InitializedTree
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Init for T where
T: 'static + Default,
[src]
T: 'static + Default,
fn init(
&mut HashMap<TypeId, RefCell<Box<dyn Any + 'static>>, RandomState>
) -> Option<T>
[src]
&mut HashMap<TypeId, RefCell<Box<dyn Any + 'static>>, RandomState>
) -> Option<T>
fn self_def() -> TypeInitDef
[src]
fn deps_list() -> &'static [TypeInitDef]
[src]
fn deep_deps_list(&mut Vec<TypeInitDef>, u32)
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,