pub struct NegativeInteger(/* private fields */);Implementations§
Source§impl NegativeInteger
impl NegativeInteger
Sourcepub unsafe fn new_unchecked(n: BigInt) -> Self
pub unsafe fn new_unchecked(n: BigInt) -> Self
Creates a new negative integer from the given BigInt.
§Safety
The input value must but a negative integer.
Sourcepub unsafe fn from_bytes_be_unchecked(bytes: &[u8]) -> Self
pub unsafe fn from_bytes_be_unchecked(bytes: &[u8]) -> Self
Creates a negative integer from its unsigned big endian bytes representation.
§Safety
The represented number must be negative.
Sourcepub unsafe fn from_bytes_le_unchecked(bytes: &[u8]) -> Self
pub unsafe fn from_bytes_le_unchecked(bytes: &[u8]) -> Self
Creates a negative integer from its unsigned little endian bytes representation.
§Safety
The represented number must be negative.
Sourcepub unsafe fn from_signed_bytes_be_unchecked(bytes: &[u8]) -> Self
pub unsafe fn from_signed_bytes_be_unchecked(bytes: &[u8]) -> Self
Creates a negative integer from its signed big endian bytes representation.
§Safety
The represented number must be negative.
Sourcepub unsafe fn from_signed_bytes_le_unchecked(bytes: &[u8]) -> Self
pub unsafe fn from_signed_bytes_le_unchecked(bytes: &[u8]) -> Self
Creates a negative integer from its signed little endian bytes representation.
§Safety
The represented number must be negative.
pub fn into_big_int(self) -> BigInt
pub fn is_minus_one(&self) -> bool
pub fn to_bytes_be(&self) -> (Sign, Vec<u8>)
pub fn to_bytes_le(&self) -> (Sign, Vec<u8>)
pub fn to_signed_bytes_be(&self) -> Vec<u8> ⓘ
pub fn to_signed_bytes_le(&self) -> Vec<u8> ⓘ
Trait Implementations§
Source§impl Add<Integer> for NegativeInteger
impl Add<Integer> for NegativeInteger
Source§impl Add<NegativeInteger> for NonNegativeInteger
impl Add<NegativeInteger> for NonNegativeInteger
Source§type Output = NonNegativeInteger
type Output = NonNegativeInteger
The resulting type after applying the
+ operator.Source§impl Add<NegativeInteger> for NonPositiveInteger
impl Add<NegativeInteger> for NonPositiveInteger
Source§type Output = NonPositiveInteger
type Output = NonPositiveInteger
The resulting type after applying the
+ operator.Source§impl Add<NegativeInteger> for PositiveInteger
impl Add<NegativeInteger> for PositiveInteger
Source§type Output = PositiveInteger
type Output = PositiveInteger
The resulting type after applying the
+ operator.Source§impl Add<NonNegativeInteger> for NegativeInteger
impl Add<NonNegativeInteger> for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
+ operator.Source§impl Add<NonPositiveInteger> for NegativeInteger
impl Add<NonPositiveInteger> for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
+ operator.Source§impl Add<PositiveInteger> for NegativeInteger
impl Add<PositiveInteger> for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
+ operator.Source§impl Add<i16> for NegativeInteger
impl Add<i16> for NegativeInteger
Source§impl Add<i32> for NegativeInteger
impl Add<i32> for NegativeInteger
Source§impl Add<i64> for NegativeInteger
impl Add<i64> for NegativeInteger
Source§impl Add<i8> for NegativeInteger
impl Add<i8> for NegativeInteger
Source§impl Add<isize> for NegativeInteger
impl Add<isize> for NegativeInteger
Source§impl Add<u16> for NegativeInteger
impl Add<u16> for NegativeInteger
Source§impl Add<u32> for NegativeInteger
impl Add<u32> for NegativeInteger
Source§impl Add<u64> for NegativeInteger
impl Add<u64> for NegativeInteger
Source§impl Add<u8> for NegativeInteger
impl Add<u8> for NegativeInteger
Source§impl Add<usize> for NegativeInteger
impl Add<usize> for NegativeInteger
Source§impl Add for NegativeInteger
impl Add for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
+ operator.Source§impl Clone for NegativeInteger
impl Clone for NegativeInteger
Source§fn clone(&self) -> NegativeInteger
fn clone(&self) -> NegativeInteger
Returns a duplicate of the value. Read more
1.0.0 · 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 NegativeInteger
impl Debug for NegativeInteger
Source§impl Display for NegativeInteger
impl Display for NegativeInteger
Source§impl Div<Integer> for NegativeInteger
impl Div<Integer> for NegativeInteger
Source§impl Div<NegativeInteger> for NonNegativeInteger
impl Div<NegativeInteger> for NonNegativeInteger
Source§type Output = NonNegativeInteger
type Output = NonNegativeInteger
The resulting type after applying the
/ operator.Source§impl Div<NegativeInteger> for NonPositiveInteger
impl Div<NegativeInteger> for NonPositiveInteger
Source§type Output = NonPositiveInteger
type Output = NonPositiveInteger
The resulting type after applying the
/ operator.Source§impl Div<NegativeInteger> for PositiveInteger
impl Div<NegativeInteger> for PositiveInteger
Source§type Output = PositiveInteger
type Output = PositiveInteger
The resulting type after applying the
/ operator.Source§impl Div<NonNegativeInteger> for NegativeInteger
impl Div<NonNegativeInteger> for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
/ operator.Source§impl Div<NonPositiveInteger> for NegativeInteger
impl Div<NonPositiveInteger> for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
/ operator.Source§impl Div<PositiveInteger> for NegativeInteger
impl Div<PositiveInteger> for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
/ operator.Source§impl Div<i16> for NegativeInteger
impl Div<i16> for NegativeInteger
Source§impl Div<i32> for NegativeInteger
impl Div<i32> for NegativeInteger
Source§impl Div<i64> for NegativeInteger
impl Div<i64> for NegativeInteger
Source§impl Div<i8> for NegativeInteger
impl Div<i8> for NegativeInteger
Source§impl Div<isize> for NegativeInteger
impl Div<isize> for NegativeInteger
Source§impl Div<u16> for NegativeInteger
impl Div<u16> for NegativeInteger
Source§impl Div<u32> for NegativeInteger
impl Div<u32> for NegativeInteger
Source§impl Div<u64> for NegativeInteger
impl Div<u64> for NegativeInteger
Source§impl Div<u8> for NegativeInteger
impl Div<u8> for NegativeInteger
Source§impl Div<usize> for NegativeInteger
impl Div<usize> for NegativeInteger
Source§impl Div for NegativeInteger
impl Div for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
/ operator.Source§impl From<NegativeInteger> for BigInt
impl From<NegativeInteger> for BigInt
Source§fn from(value: NegativeInteger) -> Self
fn from(value: NegativeInteger) -> Self
Converts to this type from the input type.
Source§impl Hash for NegativeInteger
impl Hash for NegativeInteger
Source§impl LexicalFormOf<NegativeInteger> for NegativeInteger
impl LexicalFormOf<NegativeInteger> for NegativeInteger
type ValueError = Infallible
fn try_as_value(&self) -> Result<NegativeInteger, Self::ValueError>
fn as_value(&self) -> Vwhere
Self: LexicalFormOf<V, ValueError = Infallible>,
Source§impl Mul<Integer> for NegativeInteger
impl Mul<Integer> for NegativeInteger
Source§impl Mul<NegativeInteger> for NonNegativeInteger
impl Mul<NegativeInteger> for NonNegativeInteger
Source§type Output = NonNegativeInteger
type Output = NonNegativeInteger
The resulting type after applying the
* operator.Source§impl Mul<NegativeInteger> for NonPositiveInteger
impl Mul<NegativeInteger> for NonPositiveInteger
Source§type Output = NonPositiveInteger
type Output = NonPositiveInteger
The resulting type after applying the
* operator.Source§impl Mul<NegativeInteger> for PositiveInteger
impl Mul<NegativeInteger> for PositiveInteger
Source§type Output = PositiveInteger
type Output = PositiveInteger
The resulting type after applying the
* operator.Source§impl Mul<NonNegativeInteger> for NegativeInteger
impl Mul<NonNegativeInteger> for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
* operator.Source§impl Mul<NonPositiveInteger> for NegativeInteger
impl Mul<NonPositiveInteger> for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
* operator.Source§impl Mul<PositiveInteger> for NegativeInteger
impl Mul<PositiveInteger> for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
* operator.Source§impl Mul<i16> for NegativeInteger
impl Mul<i16> for NegativeInteger
Source§impl Mul<i32> for NegativeInteger
impl Mul<i32> for NegativeInteger
Source§impl Mul<i64> for NegativeInteger
impl Mul<i64> for NegativeInteger
Source§impl Mul<i8> for NegativeInteger
impl Mul<i8> for NegativeInteger
Source§impl Mul<isize> for NegativeInteger
impl Mul<isize> for NegativeInteger
Source§impl Mul<u16> for NegativeInteger
impl Mul<u16> for NegativeInteger
Source§impl Mul<u32> for NegativeInteger
impl Mul<u32> for NegativeInteger
Source§impl Mul<u64> for NegativeInteger
impl Mul<u64> for NegativeInteger
Source§impl Mul<u8> for NegativeInteger
impl Mul<u8> for NegativeInteger
Source§impl Mul<usize> for NegativeInteger
impl Mul<usize> for NegativeInteger
Source§impl Mul for NegativeInteger
impl Mul for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
* operator.Source§impl Ord for NegativeInteger
impl Ord for NegativeInteger
Source§fn cmp(&self, other: &NegativeInteger) -> Ordering
fn cmp(&self, other: &NegativeInteger) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl ParseXsd for NegativeInteger
impl ParseXsd for NegativeInteger
type LexicalForm = NegativeInteger
fn parse_xsd(lexical_value: &str) -> ParseXsdResult<Self, Self::LexicalForm>
Source§impl PartialEq for NegativeInteger
impl PartialEq for NegativeInteger
Source§impl PartialOrd for NegativeInteger
impl PartialOrd for NegativeInteger
Source§impl Sub<Integer> for NegativeInteger
impl Sub<Integer> for NegativeInteger
Source§impl Sub<NegativeInteger> for NonNegativeInteger
impl Sub<NegativeInteger> for NonNegativeInteger
Source§type Output = NonNegativeInteger
type Output = NonNegativeInteger
The resulting type after applying the
- operator.Source§impl Sub<NegativeInteger> for NonPositiveInteger
impl Sub<NegativeInteger> for NonPositiveInteger
Source§type Output = NonPositiveInteger
type Output = NonPositiveInteger
The resulting type after applying the
- operator.Source§impl Sub<NegativeInteger> for PositiveInteger
impl Sub<NegativeInteger> for PositiveInteger
Source§type Output = PositiveInteger
type Output = PositiveInteger
The resulting type after applying the
- operator.Source§impl Sub<NonNegativeInteger> for NegativeInteger
impl Sub<NonNegativeInteger> for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
- operator.Source§impl Sub<NonPositiveInteger> for NegativeInteger
impl Sub<NonPositiveInteger> for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
- operator.Source§impl Sub<PositiveInteger> for NegativeInteger
impl Sub<PositiveInteger> for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
- operator.Source§impl Sub<i16> for NegativeInteger
impl Sub<i16> for NegativeInteger
Source§impl Sub<i32> for NegativeInteger
impl Sub<i32> for NegativeInteger
Source§impl Sub<i64> for NegativeInteger
impl Sub<i64> for NegativeInteger
Source§impl Sub<i8> for NegativeInteger
impl Sub<i8> for NegativeInteger
Source§impl Sub<isize> for NegativeInteger
impl Sub<isize> for NegativeInteger
Source§impl Sub<u16> for NegativeInteger
impl Sub<u16> for NegativeInteger
Source§impl Sub<u32> for NegativeInteger
impl Sub<u32> for NegativeInteger
Source§impl Sub<u64> for NegativeInteger
impl Sub<u64> for NegativeInteger
Source§impl Sub<u8> for NegativeInteger
impl Sub<u8> for NegativeInteger
Source§impl Sub<usize> for NegativeInteger
impl Sub<usize> for NegativeInteger
Source§impl Sub for NegativeInteger
impl Sub for NegativeInteger
Source§type Output = NegativeInteger
type Output = NegativeInteger
The resulting type after applying the
- operator.Source§impl XsdValue for NegativeInteger
impl XsdValue for NegativeInteger
impl Eq for NegativeInteger
impl StructuralPartialEq for NegativeInteger
Auto Trait Implementations§
impl Freeze for NegativeInteger
impl RefUnwindSafe for NegativeInteger
impl Send for NegativeInteger
impl Sync for NegativeInteger
impl Unpin for NegativeInteger
impl UnwindSafe for NegativeInteger
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