#[non_exhaustive]pub struct TransformOptionsPayload {Show 19 fields
pub width: Option<u32>,
pub height: Option<u32>,
pub fit: Option<String>,
pub position: Option<String>,
pub format: Option<String>,
pub quality: Option<u8>,
pub optimize: Option<String>,
pub target_quality: Option<String>,
pub background: Option<String>,
pub rotate: Option<i32>,
pub auto_orient: Option<bool>,
pub strip_metadata: Option<bool>,
pub preserve_exif: Option<bool>,
pub crop: Option<String>,
pub blur: Option<f32>,
pub sharpen: Option<f32>,
pub grayscale: Option<bool>,
pub without_enlargement: Option<bool>,
pub preset: Option<String>,
}Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.width: Option<u32>§height: Option<u32>§fit: Option<String>§position: Option<String>§format: Option<String>§quality: Option<u8>§optimize: Option<String>§target_quality: Option<String>§background: Option<String>§rotate: Option<i32>Clockwise rotation in whole degrees. Negatives turn counter-clockwise and values
past a full turn wrap, which is what Rotation accepts and what the CLI and the
Wasm package take.
auto_orient: Option<bool>§strip_metadata: Option<bool>§preserve_exif: Option<bool>§crop: Option<String>§blur: Option<f32>§sharpen: Option<f32>§grayscale: Option<bool>§without_enlargement: Option<bool>§preset: Option<String>Name of a server-side transform preset, whose fields this request’s own fields override.
Every route that takes transform options takes this one, which is what
docs/openapi.yaml declares and what presets are for: the vocabulary lives on the
server rather than in each caller. It is not a field a preset may itself set —
parse_presets refuses it — so a preset cannot name another one.
Trait Implementations§
Source§impl Clone for TransformOptionsPayload
impl Clone for TransformOptionsPayload
Source§fn clone(&self) -> TransformOptionsPayload
fn clone(&self) -> TransformOptionsPayload
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 Debug for TransformOptionsPayload
impl Debug for TransformOptionsPayload
Source§impl Default for TransformOptionsPayload
impl Default for TransformOptionsPayload
Source§fn default() -> TransformOptionsPayload
fn default() -> TransformOptionsPayload
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for TransformOptionsPayloadwhere
TransformOptionsPayload: Default,
impl<'de> Deserialize<'de> for TransformOptionsPayloadwhere
TransformOptionsPayload: Default,
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 TransformOptionsPayload
impl PartialEq for TransformOptionsPayload
impl StructuralPartialEq for TransformOptionsPayload
Auto Trait Implementations§
impl Freeze for TransformOptionsPayload
impl RefUnwindSafe for TransformOptionsPayload
impl Send for TransformOptionsPayload
impl Sync for TransformOptionsPayload
impl Unpin for TransformOptionsPayload
impl UnsafeUnpin for TransformOptionsPayload
impl UnwindSafe for TransformOptionsPayload
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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