Chemical Data Processing Library C++ API - Version 1.0.0
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Classes | Public Member Functions | List of all members
CDPL::Chem::BondDirectionCalculator Class Reference

BondDirectionCalculator. More...

#include <BondDirectionCalculator.hpp>

Public Member Functions

 BondDirectionCalculator ()
 Construcst the BondDirectionCalculator instance. More...
 
 BondDirectionCalculator (const MolecularGraph &molgraph, Util::UIArray &dirs)
 Constructs the BondDirectionCalculator instance and calculates direction flags for a minimum set of directional bonds that unambiguously define the configuration of double bonds in the molecular graph molgraph. More...
 
void includeRingBonds (bool include)
 Allows to specify whether or not the configuration of ring double bonds shall also be regarded in the performed bond direction calculations. More...
 
bool ringBondsIncluded () const
 Tells whether the configuration of ring double bonds is also regarded in the performed bond direction calculations. More...
 
void setRingSizeLimit (std::size_t min_size)
 Sets the minimum ring size that is required for ring double bonds to be considered in the performed bond direction calculations. More...
 
std::size_t getRingSizeLimit () const
 Returns the minimum ring size that is required for ring double bonds to be considered in the performed bond direction calculations. More...
 
void calculate (const MolecularGraph &molgraph, Util::UIArray &dirs)
 Calculates direction flags for a minimum set of directional bonds that unambiguously define the configuration of double bonds in the molecular graph molgraph. More...
 

Detailed Description

BondDirectionCalculator.

See also
[SMILES]

Constructor & Destructor Documentation

◆ BondDirectionCalculator() [1/2]

CDPL::Chem::BondDirectionCalculator::BondDirectionCalculator ( )

Construcst the BondDirectionCalculator instance.

◆ BondDirectionCalculator() [2/2]

CDPL::Chem::BondDirectionCalculator::BondDirectionCalculator ( const MolecularGraph molgraph,
Util::UIArray dirs 
)

Constructs the BondDirectionCalculator instance and calculates direction flags for a minimum set of directional bonds that unambiguously define the configuration of double bonds in the molecular graph molgraph.

Parameters
molgraphThe molecular graph for which to calculate the bond direction flags.
dirsAn array containing the calculated bond direction flags (possible values are defined as constants in namespace Chem::BondDirection). The directions are stored in the same order as the bonds appear in the bond list of the molecular graph (i.e. the direction flag of a bond is accessible via its index).

Member Function Documentation

◆ includeRingBonds()

void CDPL::Chem::BondDirectionCalculator::includeRingBonds ( bool  include)

Allows to specify whether or not the configuration of ring double bonds shall also be regarded in the performed bond direction calculations.

Parameters
includeIf true, ring double bond geometries will be taken into consideration and get ignored otherwise.
Note
By default, the configuration of ring double bonds is taken into consideration.
See also
setRingSizeLimit()

◆ ringBondsIncluded()

bool CDPL::Chem::BondDirectionCalculator::ringBondsIncluded ( ) const

Tells whether the configuration of ring double bonds is also regarded in the performed bond direction calculations.

Returns
true if ring double bond geometries are taken into consideration, and false otherwise.
See also
setRingSizeLimit()

◆ setRingSizeLimit()

void CDPL::Chem::BondDirectionCalculator::setRingSizeLimit ( std::size_t  min_size)

Sets the minimum ring size that is required for ring double bonds to be considered in the performed bond direction calculations.

Parameters
min_sizeThe minimum required ring size.
Note
The default minimum ring size is set to 8. This settings is only effective when the general inclusion of ring double bonds is not disabled (see includeRingBonds()).

◆ getRingSizeLimit()

std::size_t CDPL::Chem::BondDirectionCalculator::getRingSizeLimit ( ) const

Returns the minimum ring size that is required for ring double bonds to be considered in the performed bond direction calculations.

Returns
The minimum required ring size.

◆ calculate()

void CDPL::Chem::BondDirectionCalculator::calculate ( const MolecularGraph molgraph,
Util::UIArray dirs 
)

Calculates direction flags for a minimum set of directional bonds that unambiguously define the configuration of double bonds in the molecular graph molgraph.

Parameters
molgraphThe molecular graph for which to calculate the bond direction flags.
dirsAn array containing the calculated bond direction flags (possible values are defined as constants in namespace Chem::BondDirection). The directions are stored in the same order as the bonds appear in the bond list of the molecular graph (i.e. the direction flag of a bond is accessible via its index).

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