pub struct PersonalThumbnailMaterializationRequest { /* private fields */ }Expand description
Owned personal-cache fallback materialization request for async or runtime-specific adapters.
Constructing this request does not perform filesystem I/O. Validation and materialization
happen only when Self::materialize_path or Self::materialize_png_bytes is called.
Implementations§
Source§impl PersonalThumbnailMaterializationRequest
impl PersonalThumbnailMaterializationRequest
Sourcepub fn new(
root: PersonalCacheRoot,
original: ReadablePersonalOriginalIdentity,
size: ThumbnailSize,
) -> Self
pub fn new( root: PersonalCacheRoot, original: ReadablePersonalOriginalIdentity, size: ThumbnailSize, ) -> Self
Creates an owned personal-cache materialization request.
Sourcepub fn materialize_path(
self,
) -> Result<PersonalThumbnailLookup<MaterializedThumbnailPath>>
pub fn materialize_path( self, ) -> Result<PersonalThumbnailLookup<MaterializedThumbnailPath>>
Materializes the requested personal namespace and returns its path.
§Errors
Returns the same errors as
PersonalCacheRoot::materialize_thumbnail_from_larger_cache_returning_path.
Sourcepub fn materialize_png_bytes(
self,
) -> Result<PersonalThumbnailLookup<MaterializedThumbnailPngBytes>>
pub fn materialize_png_bytes( self, ) -> Result<PersonalThumbnailLookup<MaterializedThumbnailPngBytes>>
Materializes the requested personal namespace and returns final PNG bytes.
§Errors
Returns the same errors as
PersonalCacheRoot::materialize_thumbnail_from_larger_cache_returning_png_bytes.
Sourcepub fn into_parts(self) -> PersonalThumbnailMaterializationRequestParts
pub fn into_parts(self) -> PersonalThumbnailMaterializationRequestParts
Splits this request into its owned parts.
Trait Implementations§
Source§impl Clone for PersonalThumbnailMaterializationRequest
impl Clone for PersonalThumbnailMaterializationRequest
Source§fn clone(&self) -> PersonalThumbnailMaterializationRequest
fn clone(&self) -> PersonalThumbnailMaterializationRequest
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl PartialEq for PersonalThumbnailMaterializationRequest
impl PartialEq for PersonalThumbnailMaterializationRequest
Source§fn eq(&self, other: &PersonalThumbnailMaterializationRequest) -> bool
fn eq(&self, other: &PersonalThumbnailMaterializationRequest) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for PersonalThumbnailMaterializationRequest
impl StructuralPartialEq for PersonalThumbnailMaterializationRequest
Auto Trait Implementations§
impl Freeze for PersonalThumbnailMaterializationRequest
impl RefUnwindSafe for PersonalThumbnailMaterializationRequest
impl Send for PersonalThumbnailMaterializationRequest
impl Sync for PersonalThumbnailMaterializationRequest
impl Unpin for PersonalThumbnailMaterializationRequest
impl UnsafeUnpin for PersonalThumbnailMaterializationRequest
impl UnwindSafe for PersonalThumbnailMaterializationRequest
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more