pub enum AssetKind {
Image,
Svg,
Font,
Unknown(String),
}Expand description
The kind of an asset — determines how bytes are interpreted by consumers.
Mirrors TokenType: unknown kind strings are preserved as
AssetKind::Unknown(String) for forward-compat. Parse is infallible;
validation emits asset.invalid_kind for unrecognized variants.
Variants§
Image
A raster image (PNG, JPEG, …).
Svg
An SVG vector graphic.
Font
A font file (TTF, OTF, WOFF2, …).
Unknown(String)
An unrecognized asset kind (forward-compat; version-relative).
Implementations§
Trait Implementations§
impl Eq for AssetKind
impl StructuralPartialEq for AssetKind
Auto Trait Implementations§
impl Freeze for AssetKind
impl RefUnwindSafe for AssetKind
impl Send for AssetKind
impl Sync for AssetKind
impl Unpin for AssetKind
impl UnsafeUnpin for AssetKind
impl UnwindSafe for AssetKind
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