pub struct ModelTable { /* private fields */ }Expand description
The models of a structure, in deposition order.
Implementations§
Source§impl ModelTable
impl ModelTable
Sourcepub fn push(
&mut self,
model_num: i32,
chains: Range<u32>,
) -> Result<ModelIndex, TableError>
pub fn push( &mut self, model_num: i32, chains: Range<u32>, ) -> Result<ModelIndex, TableError>
Appends a model covering a range of chains.
§Errors
Returns TableError for a reversed range or exhausted index space.
Sourcepub fn model_num(&self, model: ModelIndex) -> Option<i32>
pub fn model_num(&self, model: ModelIndex) -> Option<i32>
The number the model was deposited under.
Never renumbered. A file whose models are 1, 5 and 7 keeps those numbers, because a result that cites model 5 must mean the same model the depositor called 5.
Sourcepub fn iter(&self) -> impl Iterator<Item = ModelIndex> + '_
pub fn iter(&self) -> impl Iterator<Item = ModelIndex> + '_
Every model position.
Trait Implementations§
Source§impl Clone for ModelTable
impl Clone for ModelTable
Source§impl Debug for ModelTable
impl Debug for ModelTable
Auto Trait Implementations§
impl Freeze for ModelTable
impl RefUnwindSafe for ModelTable
impl Send for ModelTable
impl Sync for ModelTable
impl Unpin for ModelTable
impl UnsafeUnpin for ModelTable
impl UnwindSafe for ModelTable
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