The proto-Nucleic-Acid Builder (pNAB)
|
Class to fully define bases (i.e. Adenine, Cytosine) More...
#include <Containers.h>
Public Member Functions | |
Base () | |
Empty constructor. More... | |
Base (std::string name, std::string code, std::string file_path, std::array< std::size_t, 2 > linker, std::string pair_name="") | |
Create Base from basic set of parameters. More... | |
OpenBabel::OBAtom * | getLinker () |
Gives the atom of the base that connects directly to the backbone, Base::linker[0]. More... | |
OpenBabel::OBAtom * | getVector () |
Gives the (most likely hydrogen) atom of the base connected to the atom from getLinker() which defines how the base connects, Base::linker[1]. More... | |
OpenBabel::OBMol | getMolecule () |
Returns a copy of the base molecule, Base::base. More... | |
std::string | getCode () |
Gives the three-letter code of the base, Base::code. More... | |
std::string | getName () |
Gives the full name of the base, Base::name. More... | |
void | deleteVectorAtom () |
Deletes the atom from getVector() safely. If the atom is already deleted, nothing happens. More... | |
std::string | getBasePairName () |
Get the name of the pair base, Base::pair_name. More... | |
Public Attributes | |
std::string | name |
Full name of base (i.e. "Adenine" or just "A") More... | |
std::string | code |
Three character code to define base ("Adenine": "ADE") More... | |
std::string | pair_name |
Name of the pair base. More... | |
std::string | file_path |
Path to a file containing the base. More... | |
OpenBabel::OBMol | base |
The OBMol defining the base. More... | |
std::array< std::size_t, 2 > | linker |
Holds indices for atoms forming a vector to connect to backbone {linker, hydrogen}. More... | |
Private Member Functions | |
void | validate () |
Does some basic sanity checks (such as whether or not the indices of the atom are within the range of the molecule). More... | |
Private Attributes | |
bool | vector_atom_deleted |
Whether or not the getVector() atom was deleted. More... | |
Class to fully define bases (i.e. Adenine, Cytosine)
This class holds information on the molecular structure of one nucleobase and the bond that it should form with the backbone. This class also has functions to manipulate the nucleobase and gets information about it.
|
inline |
Empty constructor.
This empty constructor can be used. After that, values for the member variables should be specified.
Base::Base | ( | std::string | name, |
std::string | code, | ||
std::string | file_path, | ||
std::array< std::size_t, 2 > | linker, | ||
std::string | pair_name = "" |
||
) |
Create Base from basic set of parameters.
name | name of the base |
code | three-letter code |
file_path | path to the backbone file |
linker | indices for atoms forming the vector connecting to the backbone |
pair_name | Name of the pairing base |
|
inline |
Deletes the atom from getVector() safely. If the atom is already deleted, nothing happens.
|
inline |
Get the name of the pair base, Base::pair_name.
|
inline |
Gives the three-letter code of the base, Base::code.
|
inline |
Gives the atom of the base that connects directly to the backbone, Base::linker[0].
|
inline |
Returns a copy of the base molecule, Base::base.
|
inline |
Gives the full name of the base, Base::name.
|
inline |
Gives the (most likely hydrogen) atom of the base connected to the atom from getLinker() which defines how the base connects, Base::linker[1].
|
private |
Does some basic sanity checks (such as whether or not the indices of the atom are within the range of the molecule).
OpenBabel::OBMol PNAB::Base::base |
The OBMol defining the base.
std::string PNAB::Base::code |
Three character code to define base ("Adenine": "ADE")
std::string PNAB::Base::file_path |
Path to a file containing the base.
std::array<std::size_t, 2 > PNAB::Base::linker |
Holds indices for atoms forming a vector to connect to backbone {linker, hydrogen}.
std::string PNAB::Base::name |
Full name of base (i.e. "Adenine" or just "A")
std::string PNAB::Base::pair_name |
Name of the pair base.
|
private |
Whether or not the getVector() atom was deleted.