pub struct Positive<T: Float>(/* private fields */);
Expand description
Positive floating point number
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Positive<f64>
impl<'de> Deserialize<'de> for Positive<f64>
Source§fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
Source§impl JsonSchema for Positive<f64>
impl JsonSchema for Positive<f64>
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(_gen: &mut SchemaGenerator) -> Schema
fn json_schema(_gen: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
§fn always_inline_schema() -> bool
fn always_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<T: PartialOrd + Float> PartialOrd for Positive<T>
impl<T: PartialOrd + Float> PartialOrd for Positive<T>
impl<T: Copy + Float> Copy for Positive<T>
impl<T: Float> StructuralPartialEq for Positive<T>
Auto Trait Implementations§
impl<T> Freeze for Positive<T>where
T: Freeze,
impl<T> RefUnwindSafe for Positive<T>where
T: RefUnwindSafe,
impl<T> Send for Positive<T>where
T: Send,
impl<T> Sync for Positive<T>where
T: Sync,
impl<T> Unpin for Positive<T>where
T: Unpin,
impl<T> UnwindSafe for Positive<T>where
T: UnwindSafe,
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)