pub struct FrameColumns<'a> { /* private fields */ }Expand description
Borrowed per-frame columns: coordinates and per-atom scalars.
Every accessor returns a slice of the model’s own
AtomicConformation storage; nothing is copied.
The borrow checker keeps the model alive and unmodified for 'a. Pointers
handed across FFI from these slices carry the same rule, unenforced: they
are valid until the model is dropped or its conformation is mutated.
Implementations§
Source§impl<'a> FrameColumns<'a>
impl<'a> FrameColumns<'a>
Sourcepub fn new(model: &'a Model) -> Result<Self, BoundaryError>
pub fn new(model: &'a Model) -> Result<Self, BoundaryError>
Borrow the per-frame columns of model, validating their lengths.
Prefer TopologyColumns::frame, which
also checks that the frame belongs to a given topology snapshot.
Sourcepub fn confidence(&self) -> Option<&'a [f32]>
pub fn confidence(&self) -> Option<&'a [f32]>
Per-atom confidence (e.g. pLDDT), if recorded.
Sourcepub fn columns(&self) -> Vec<Column<'a>>
pub fn columns(&self) -> Vec<Column<'a>>
Every present per-frame column by stable name. Absent optional columns are omitted.
Sourcepub fn positions(&self, layout: PositionLayout) -> GpuBuffer<'static>
pub fn positions(&self, layout: PositionLayout) -> GpuBuffer<'static>
Interleave x/y/z into one position buffer. Always an owned copy, since the model stores coordinates as separate SoA columns.
Trait Implementations§
Source§impl<'a> Clone for FrameColumns<'a>
impl<'a> Clone for FrameColumns<'a>
Source§fn clone(&self) -> FrameColumns<'a>
fn clone(&self) -> FrameColumns<'a>
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl<'a> Copy for FrameColumns<'a>
Auto Trait Implementations§
impl<'a> Freeze for FrameColumns<'a>
impl<'a> RefUnwindSafe for FrameColumns<'a>
impl<'a> Send for FrameColumns<'a>
impl<'a> Sync for FrameColumns<'a>
impl<'a> Unpin for FrameColumns<'a>
impl<'a> UnsafeUnpin for FrameColumns<'a>
impl<'a> UnwindSafe for FrameColumns<'a>
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
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> ⓘ
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> ⓘ
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