OESameSubSearchScreenTypes¶
Attention
This API is currently available in C++ and Python.
bool OESameSubSearchScreenTypes(const OESubSearchScreen &,
const OESubSearchScreen &)
Returns whether or not the types (OESubSearchScreenTypeBase) of the two OESubSearchScreen objects are the same.
Example:
int main(int, char* [])
{
OEQMol qmol;
OEParseSmarts(qmol, "c1cc[o,n,s]c1");
OESubSearchScreen qscreen;
OEMakeSubSearchQueryScreen(qscreen, qmol, OESubSearchScreenType::SMARTS);
OEGraphMol tmol;
OEParseSmiles(tmol, "c1ccoc1");
OESubSearchScreen tscreen;
OEMakeSubSearchTargetScreen(tscreen, tmol, OESubSearchScreenType::MDL);
if (OESameSubSearchScreenTypes(qscreen, tscreen))
std::cout << "same screen types" << std::endl;
else
std::cout << "different screen types" << std::endl;
return 0;
}
Warning
Screens with different types should never be compared with each other since they have been generated with different algorithms, they might have different lengths and their bits can represent different molecular features.
See also
OEGetSubSearchScreenType
functionOESubSearchScreenType
namespace