[]Struct lumol::sys::Bonding

pub struct Bonding { /* fields omitted */ }

The basic building block for a topology. A Bonding contains data about the connectivity (bonds, angles, dihedrals) between particles in a single molecule.

Methods

impl Bonding

pub fn new(i: usize) -> Bonding

Create a new Bonding containing only the atom i

pub fn size(&self) -> usize

Get the number of atoms in the molecule

pub fn start(&self) -> usize

Get the first atom of this molecule

pub fn end(&self) -> usize

Get the index of the first atom after this molecule

pub fn contains(&self, i: usize) -> bool

Does this molecule contains the particle i

pub fn merge_with(&mut self, other: Bonding)

Merge this molecule with other. The first particle in other should be the particle just after the last one in self.

pub fn translate_by(&mut self, delta: isize)

Translate all indexes in this molecule by delta.

pub fn add_bond(&mut self, i: usize, j: usize)

Add a bond between the particles at indexes i and j. These particles are assumed to be in the molecule

pub fn remove_particle(&mut self, i: usize)

Removes particle at index i and any associated bonds, angle or dihedral. This function also update the indexes for the bonds/angles/dihedral by remove 1 to all the values > i

pub fn bonds(&self) -> &HashSet<Bond, RandomState>

Get the internal list of bonds

pub fn angles(&self) -> &HashSet<Angle, RandomState>

Get the internal list of angles

pub fn dihedrals(&self) -> &HashSet<Dihedral, RandomState>

Get the internal list of dihedrals

pub fn bond_distances(&self, i: usize, j: usize) -> BondDistances

Get the all the possible bond paths the particles i and j in this molecule

pub fn indexes(&self) -> Range<usize>

Get the indexes of the particles in this molecule. All atoms in the returned range are inside this molecule.

Trait Implementations

impl Clone for Bonding

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl Debug for Bonding

Auto Trait Implementations

impl Send for Bonding

impl Sync for Bonding

Blanket Implementations

impl<T> From for T[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T, U> TryFrom for T where
    T: From<U>, 
[src]

type Error = !

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]