pub struct OutOfRangeError {
pub bitarray_size: i64,
pub bitarray_position: i64,
}
Expand description
Struct represents a custom error that should be raised every time a user tries to access or set the bit in the array that is out of this bit array size.
Fields§
§bitarray_size: i64
§bitarray_position: i64
Implementations§
Source§impl OutOfRangeError
impl OutOfRangeError
Sourcepub fn new(bitarray_size: i64, bitarray_position: i64) -> Self
pub fn new(bitarray_size: i64, bitarray_position: i64) -> Self
Constructor used to initialize a new OutOfRangeError with a given bitarray_size and bitarray_position. “bitarray_size” - The size in bits of the bitarray where the error was raised. “bitarray_position” - The wrong position caused an error.
Trait Implementations§
Source§impl Clone for OutOfRangeError
impl Clone for OutOfRangeError
Source§fn clone(&self) -> OutOfRangeError
fn clone(&self) -> OutOfRangeError
Returns a copy 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 OutOfRangeError
impl Debug for OutOfRangeError
Auto Trait Implementations§
impl Freeze for OutOfRangeError
impl RefUnwindSafe for OutOfRangeError
impl Send for OutOfRangeError
impl Sync for OutOfRangeError
impl Unpin for OutOfRangeError
impl UnwindSafe for OutOfRangeError
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