| 1 |
/****************************************************************************** |
| 2 |
This source file is part of the Avogadro project. |
| 3 |
This source code is released under the 3-Clause BSD License, (see "LICENSE"). |
| 4 |
******************************************************************************/ |
| 5 |
|
| 6 |
#ifndef AVOGADRO_QTGUI_ATOMUTILITIES_H |
| 7 |
#define AVOGADRO_QTGUI_ATOMUTILITIES_H |
| 8 |
|
| 9 |
#include "avogadrocoreexport.h" |
| 10 |
|
| 11 |
#include <avogadro/core/molecule.h> |
| 12 |
|
| 13 |
#include <vector> |
| 14 |
|
| 15 |
namespace Avogadro::Core { |
| 16 |
class Atom; |
| 17 |
class Molecule; |
| 18 |
|
| 19 |
class AVOGADROCORE_EXPORT AtomUtilities |
| 20 |
{ |
| 21 |
public: |
| 22 |
/** |
| 23 |
* Perceive the geometry / hybridization bonded to @a atom. |
| 24 |
* Ideally, the client should cache the hybridization number |
| 25 |
* by calling setHybridization() later |
| 26 |
*/ |
| 27 |
static AtomHybridization perceiveHybridization(const Atom& atom); |
| 28 |
|
| 29 |
/** |
| 30 |
* Generate a new bond vector (unit length) |
| 31 |
*/ |
| 32 |
static Vector3 generateNewBondVector( |
| 33 |
const Atom& atom, const std::vector<Vector3>& currentVectors, |
| 34 |
AtomHybridization hybridization); |
| 35 |
|
| 36 |
private: |
| 37 |
AtomUtilities(); // Not implemented |
| 38 |
~AtomUtilities(); // Not implemented |
| 39 |
}; |
| 40 |
|
| 41 |
} // namespace Avogadro::Core |
| 42 |
|
| 43 |
#endif // AVOGADRO_QTGUI_ATOMUTILITIES_H |