NuriKit v0.1.0b2
Loading...
Searching...
No Matches
nuri::BondData Class Reference

#include <nuri/core/molecule.h>

Public Member Functions

 BondData ()
 BondData (constants::BondOrder order)
constants::BondOrder order () const
 Get the bond order of the bond.
double approx_order () const
 Get the approximate bond order of the bond.
constants::BondOrderorder ()
 Get the read-write reference to bond order.
BondDataset_order (constants::BondOrder order)
bool is_rotatable () const
 Test if this bond is rotatable.
bool is_ring_bond () const
BondDataset_ring_bond (bool ring)
bool is_aromatic () const
BondDataset_aromatic (bool aromatic)
bool is_conjugated () const
BondDataset_conjugated (bool conj)
bool has_config () const
 Test if the bond configuration is explicitly specified.
BondDataset_config (bool config)
 Set whether the bond configuration is explicitly specified.
bool is_trans () const
 Get the cis-trans configuration of the bond.
BondDataset_trans (bool trans)
 Set cis-trans configuration of the bond.
BondFlags flags () const
BondDataadd_flags (BondFlags flags)
BondDatadel_flags (BondFlags flags)
BondDatareset_flags ()
std::string_view get_name () const
template<class ST>
BondDataset_name (ST &&name)
template<class KT, class VT>
BondDataadd_prop (KT &&key, VT &&val)
internal::PropertyMap & props ()
const internal::PropertyMap & props () const

Constructor & Destructor Documentation

◆ BondData() [1/2]

nuri::BondData::BondData ( )
inline

◆ BondData() [2/2]

nuri::BondData::BondData ( constants::BondOrder order)
inlineexplicit

Member Function Documentation

◆ add_flags()

BondData & nuri::BondData::add_flags ( BondFlags flags)
inline

◆ add_prop()

template<class KT, class VT>
BondData & nuri::BondData::add_prop ( KT && key,
VT && val )
inline

◆ approx_order()

double nuri::BondData::approx_order ( ) const
inline

Get the approximate bond order of the bond.

Returns
Approximate bond order, e.g., 1.5 for an aromatic bond.

◆ del_flags()

BondData & nuri::BondData::del_flags ( BondFlags flags)
inline

◆ flags()

BondFlags nuri::BondData::flags ( ) const
inline

◆ get_name()

std::string_view nuri::BondData::get_name ( ) const
inline

◆ has_config()

bool nuri::BondData::has_config ( ) const
inline

Test if the bond configuration is explicitly specified.

◆ is_aromatic()

bool nuri::BondData::is_aromatic ( ) const
inline

◆ is_conjugated()

bool nuri::BondData::is_conjugated ( ) const
inline

◆ is_ring_bond()

bool nuri::BondData::is_ring_bond ( ) const
inline

◆ is_rotatable()

bool nuri::BondData::is_rotatable ( ) const
inline

Test if this bond is rotatable.

Returns
Whether the bond is rotatable. Only non-conjugated single bonds that are not part of a ring are considered rotatable.

◆ is_trans()

bool nuri::BondData::is_trans ( ) const
inline

Get the cis-trans configuration of the bond.

Returns
Whether the bond is in trans configuration.
Precondition
has_config(), otherwise return value would be meaningless.
Note
This flag is only meaningful for torsionally restricted bonds, such as double bonds.

For bonds with more than 3 neighboring atoms, "trans" configuration is not a well defined term. In such cases, this will return whether the first two neighbors are on the same side of the bond. For example, in the following structure, the bond between atoms 0 and 1 is considered to be in a cis configuration (assuming the neighbors are ordered in the same way as the atoms).

2 4
\ /
0 = 1
/ \
3 5

◆ order() [1/2]

constants::BondOrder & nuri::BondData::order ( )
inline

Get the read-write reference to bond order.

◆ order() [2/2]

constants::BondOrder nuri::BondData::order ( ) const
inline

Get the bond order of the bond.

◆ props() [1/2]

internal::PropertyMap & nuri::BondData::props ( )
inline

◆ props() [2/2]

const internal::PropertyMap & nuri::BondData::props ( ) const
inline

◆ reset_flags()

BondData & nuri::BondData::reset_flags ( )
inline

◆ set_aromatic()

BondData & nuri::BondData::set_aromatic ( bool aromatic)
inline

◆ set_config()

BondData & nuri::BondData::set_config ( bool config)
inline

Set whether the bond configuration is explicitly specified.

◆ set_conjugated()

BondData & nuri::BondData::set_conjugated ( bool conj)
inline

◆ set_name()

template<class ST>
BondData & nuri::BondData::set_name ( ST && name)
inline

◆ set_order()

BondData & nuri::BondData::set_order ( constants::BondOrder order)
inline

◆ set_ring_bond()

BondData & nuri::BondData::set_ring_bond ( bool ring)
inline

◆ set_trans()

BondData & nuri::BondData::set_trans ( bool trans)
inline

Set cis-trans configuration of the bond.

Parameters
transWhether the bond is in trans configuration or not.
Precondition
has_config()

The documentation for this class was generated from the following file: