pub struct UtcOffset { /* private fields */ }Implementations§
Source§impl UtcOffset
impl UtcOffset
pub fn get_number(&self) -> i16
pub fn is_zero(&self) -> bool
pub fn is_positive(&self) -> bool
pub fn is_negative(&self) -> bool
pub fn is_integer(&self) -> bool
pub fn from_string( input: String, ) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_str(input: &str) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_number(input: i16) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_f64(input: f64) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_f32(input: f32) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_isize(input: isize) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_i8(input: i8) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_i16(input: i16) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_i32(input: i32) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_i64(input: i64) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_i128(input: i128) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_usize(input: usize) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_u8(input: u8) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_u16(input: u16) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_u32(input: u32) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_u64(input: u64) -> Result<Self, ValidatedCustomizedNumberError>
pub fn from_u128(input: u128) -> Result<Self, ValidatedCustomizedNumberError>
pub unsafe fn from_number_unchecked(input: i16) -> Self
Trait Implementations§
Source§impl ToPrimitive for UtcOffset
impl ToPrimitive for UtcOffset
Source§fn to_isize(&self) -> Option<isize>
fn to_isize(&self) -> Option<isize>
Converts the value of
self to an isize. If the value cannot be
represented by an isize, then None is returned.Source§fn to_i8(&self) -> Option<i8>
fn to_i8(&self) -> Option<i8>
Converts the value of
self to an i8. If the value cannot be
represented by an i8, then None is returned.Source§fn to_i16(&self) -> Option<i16>
fn to_i16(&self) -> Option<i16>
Converts the value of
self to an i16. If the value cannot be
represented by an i16, then None is returned.Source§fn to_i32(&self) -> Option<i32>
fn to_i32(&self) -> Option<i32>
Converts the value of
self to an i32. If the value cannot be
represented by an i32, then None is returned.Source§fn to_i64(&self) -> Option<i64>
fn to_i64(&self) -> Option<i64>
Converts the value of
self to an i64. If the value cannot be
represented by an i64, then None is returned.Source§fn to_i128(&self) -> Option<i128>
fn to_i128(&self) -> Option<i128>
Converts the value of
self to an i128. If the value cannot be
represented by an i128 (i64 under the default implementation), then
None is returned. Read moreSource§fn to_usize(&self) -> Option<usize>
fn to_usize(&self) -> Option<usize>
Converts the value of
self to a usize. If the value cannot be
represented by a usize, then None is returned.Source§fn to_u8(&self) -> Option<u8>
fn to_u8(&self) -> Option<u8>
Converts the value of
self to a u8. If the value cannot be
represented by a u8, then None is returned.Source§fn to_u16(&self) -> Option<u16>
fn to_u16(&self) -> Option<u16>
Converts the value of
self to a u16. If the value cannot be
represented by a u16, then None is returned.Source§fn to_u32(&self) -> Option<u32>
fn to_u32(&self) -> Option<u32>
Converts the value of
self to a u32. If the value cannot be
represented by a u32, then None is returned.Source§fn to_u64(&self) -> Option<u64>
fn to_u64(&self) -> Option<u64>
Converts the value of
self to a u64. If the value cannot be
represented by a u64, then None is returned.Source§fn to_u128(&self) -> Option<u128>
fn to_u128(&self) -> Option<u128>
Converts the value of
self to a u128. If the value cannot be
represented by a u128 (u64 under the default implementation), then
None is returned. Read moreSource§impl<T: ToPrimitive> ValidatedNumberWrapper<T> for UtcOffset
impl<T: ToPrimitive> ValidatedNumberWrapper<T> for UtcOffset
fn from_number(input: T) -> Result<Self, ValidatedCustomizedNumberError>
Source§impl ValidatedWrapper for UtcOffset
impl ValidatedWrapper for UtcOffset
impl Eq for UtcOffset
impl Validated for UtcOffset
Auto Trait Implementations§
impl Freeze for UtcOffset
impl RefUnwindSafe for UtcOffset
impl Send for UtcOffset
impl Sync for UtcOffset
impl Unpin for UtcOffset
impl UnwindSafe for UtcOffset
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