pub struct Image {
pub url: String,
pub width: i64,
pub height: i64,
pub thumbnail: String,
pub source: String,
}
Expand description
Contains info about an image including the original url, the dimensions of the image (x, y), the url of the thumbnail, and the name of the source.
§Example
Image {
url: "https://www.example.com/static/image.jpg",
width: 1920,
height: 1080,
thumbnail: "https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcQQazt0j8bbA34OYbfE9hf7g_bzFGwbSZmwflwVw-rnOSOmdSX03xYzHZkm_TsmbnM3m88&usqp=CAU",
source: "https://www.example.com/articles/example.html"
}
Fields§
§url: String
§width: i64
§height: i64
§thumbnail: String
§source: String
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Image
impl RefUnwindSafe for Image
impl Send for Image
impl Sync for Image
impl Unpin for Image
impl UnwindSafe for Image
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