OEDBBuilder
Attention
This is a preliminary API and may be improved based on user feedback. It is currently available in C++ and Python.
class OEDBBuilder
This class defines an interface for building a two-dimensional Brood fragment database.
- The OEDBBuilder class defines the following public methods:
Constructors
OEDBBuilder(const OEFragmentOptions& opts = OEFragmentOptions())
Default constructor.
Add
bool Add(OEChem::OEMCMolBase& frag)
bool Add(OESystem::OEIter<OEChem::OEMCMolBase>& frag)
bool Add(const std::string& smiles)
bool Add(const std::vector<std::string>& vecSmiles)
Adds the specified fragment(s) to the database. In the SMILES-based
overloads, fragment SMILES in the format obtained from
GetFragSmiles
are expected.
AddCSV
bool AddCSV(const std::vector<std::string>& vecSmiles)
Adds fragments from the specified CSV SMILES strings. SMILES as
obtained from
GetFragSmilesCSV
are expected.
Expand
bool Expand(const OEConfGen::OEFlipperOptions& opts)
Expands the database by stereo-enumerating currently contained fragments.
Filter
bool Filter(OEMolProp::OEFilter& filter)
Filters currently contained database fragments.
Generate
bool Generate(const OEChem::OEMolBase& mol)
Generates fragments from the specified molecule and adds the generated fragment(s) to the database.
GetFrag
bool GetFrag(OEChem::OEMCMolBase& mol, const std::string& smiles) const
Obtains the fragment defined by the specified SMILES string. Returns
false if a fragment with the specified SMILES does not exist.
SMILES in the format obtained from
GetFragSmiles
is expected.
GetFragSmiles
std::vector<std::string> GetFragSmiles() const
bool GetFragSmiles(std::vector<std::string>&) const
Returns SMILES strings corresponding to the current database.
GetFragSmilesCSV
std::vector<std::string> GetFragSmilesCSV() const
bool GetFragSmilesCSV(std::vector<std::string>&) const
Returns CSV SMILES strings corresponding to the current database.
CSV SMILES contains fragment SMILES in a special
comma-separated string format.
GetFrags
OESystem::OEIterBase<OEChem::OEMCMolBase>* GetFrags() const
Returns two-dimensional fragments corresponding to the current database.
NumFrags
unsigned NumFrags() const
Returns the number of fragments corresponding to the current database.
Screen
bool Screen(const OEDBScreenOptions& opts)
Screens the fragments in the current database.