pub struct ImageVariant {
pub path: String,
pub hash: DocumentId,
pub width: u32,
pub height: u32,
pub scale: f32,
pub size: u64,
}Expand description
A resolution variant of an image for responsive display.
Fields§
§path: StringPath within the archive.
hash: DocumentIdContent hash for verification.
width: u32Image width in pixels.
height: u32Image height in pixels.
scale: f32Scale factor (e.g., 1.0 for 1x, 2.0 for 2x, 3.0 for 3x).
size: u64File size in bytes.
Implementations§
Source§impl ImageVariant
impl ImageVariant
Trait Implementations§
Source§impl Clone for ImageVariant
impl Clone for ImageVariant
Source§fn clone(&self) -> ImageVariant
fn clone(&self) -> ImageVariant
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ImageVariant
impl Debug for ImageVariant
Source§impl<'de> Deserialize<'de> for ImageVariant
impl<'de> Deserialize<'de> for ImageVariant
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for ImageVariant
impl PartialEq for ImageVariant
Source§impl Serialize for ImageVariant
impl Serialize for ImageVariant
impl StructuralPartialEq for ImageVariant
Auto Trait Implementations§
impl Freeze for ImageVariant
impl RefUnwindSafe for ImageVariant
impl Send for ImageVariant
impl Sync for ImageVariant
impl Unpin for ImageVariant
impl UnsafeUnpin for ImageVariant
impl UnwindSafe for ImageVariant
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