This class represents OEVectorBindings.
A vector binding is a SMARTS pattern bound to a name.
For example, the name
[$HALO] can be used to represent the
[$(F,Cl,Br,I)] in order to make a pattern more human
OEVectorBindings class converts SMARTS
patterns written using vector bindings (human readable form) to the
corresponding machine readable form by performing a name to pattern
OEVectorBindings() OEVectorBindings(const OEVectorBindings &)
Default and copy constructors.
OEVectorBindings &operator=(const OEVectorBindings &)
bool Add(const char *label, const char *pattern)
Adds one vector binding to an
The ‘label’ given as the first method argument is the name that
appears in the human readable version of a SMARTS, while
the ‘pattern’ given as the second method argument is the
SMARTS that should be used to replace the ‘’label’’.
If the ‘pattern’ is parsed correctly and the association is made
OEVectorBindings object, the method will return
If the ‘pattern’ is invalid or the association cannot be made
the method will return
All attempts to associate a SMARTS pattern with a
particular ‘label’ after the first association succeeds will
result subsequent failures to create new associations.
bool Get(const OEExprBase *&expr, const char *&label, const char *smarts) const
Retrieves the ‘label’ and corresponding
OEExprBase pointer reference as the first and
second method arguments, respectively, given a pointer to a
position within a smarts string given as the final
If the ‘smarts’ string position points to the beginning of a
vector bound ‘label’ contained in the
OEVectorBindings object then the method will
If the vector binding cannot be identified then the method will