pub struct RationalScale { /* private fields */ }Expand description
A positive exact rational scale in source pixels per declared coordinate unit.
Implementations§
Source§impl RationalScale
impl RationalScale
pub const fn new(numerator: NonZeroU32, denominator: NonZeroU32) -> Self
pub const fn numerator(self) -> u32
pub const fn denominator(self) -> u32
Trait Implementations§
Source§impl Clone for RationalScale
impl Clone for RationalScale
impl Copy for RationalScale
Source§impl Debug for RationalScale
impl Debug for RationalScale
Source§impl<'de> Deserialize<'de> for RationalScale
impl<'de> Deserialize<'de> for RationalScale
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
impl Eq for RationalScale
Source§impl JsonSchema for RationalScale
impl JsonSchema for RationalScale
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§impl PartialEq for RationalScale
impl PartialEq for RationalScale
Source§impl Serialize for RationalScale
impl Serialize for RationalScale
impl StructuralPartialEq for RationalScale
Auto Trait Implementations§
impl Forget for RationalScale
impl Freeze for RationalScale
impl Move for RationalScale
impl RefUnwindSafe for RationalScale
impl Send for RationalScale
impl Sync for RationalScale
impl Unpin for RationalScale
impl UnsafeUnpin for RationalScale
impl UnwindSafe for RationalScale
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