Struct bevy::asset::LoadContext[]

pub struct LoadContext<'a> { /* fields omitted */ }

Implementations

impl<'a> LoadContext<'a>

pub fn path(&self) -> &Path

pub fn has_labeled_asset(&self, label: &str) -> bool

pub fn set_default_asset<T>(&mut self, asset: LoadedAsset<T>) where
    T: Asset

pub fn set_labeled_asset<T>(
    &mut self,
    label: &str,
    asset: LoadedAsset<T>
) -> Handle<T> where
    T: Asset

pub fn get_handle<I, T>(&self, id: I) -> Handle<T> where
    T: Asset,
    I: Into<HandleId>, 

pub async fn read_asset_bytes<P>(
    &'_ self,
    path: P
) -> Result<Vec<u8, Global>, AssetIoError> where
    P: AsRef<Path>, 

pub fn get_asset_metas(&self) -> Vec<AssetMeta, Global>

Notable traits for Vec<u8, A>

impl<A> Write for Vec<u8, A> where
    A: Allocator

Auto Trait Implementations

impl<'a> !RefUnwindSafe for LoadContext<'a>

impl<'a> Send for LoadContext<'a>

impl<'a> Sync for LoadContext<'a>

impl<'a> Unpin for LoadContext<'a>

impl<'a> !UnwindSafe for LoadContext<'a>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Any for T where
    T: Any

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Component for T where
    T: 'static + Send + Sync

impl<T> Downcast for T where
    T: Any

impl<T> Downcast<T> for T

impl<T> DowncastSync for T where
    T: Any + Send + Sync

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Upcast<T> for T

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,