pub enum Source {
File(PathBuf),
Bytes {
key: Arc<str>,
data: Arc<[u8]>,
},
}Expand description
Local file or immutable named bytes. Byte identity includes the content, so reusing a name with different bytes cannot return the wrong cached asset.
Variants§
File(PathBuf)
Relative to the Assets root, or an explicitly supplied absolute path.
Bytes
Embedded bytes with a diagnostic identifier.
Trait Implementations§
impl Eq for Source
Source§impl Ord for Source
impl Ord for Source
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialOrd for Source
impl PartialOrd for Source
impl StructuralPartialEq for Source
Auto Trait Implementations§
impl Forget for Source
impl Freeze for Source
impl Move for Source
impl RefUnwindSafe for Source
impl Send for Source
impl Sync for Source
impl Unpin for Source
impl UnsafeUnpin for Source
impl UnwindSafe for Source
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