A class that defines a collection of SMARTS patterns for matching
against. The includes() method returns a list of those patterns that
should be matched, and the excludes() method returns those that
shouldn't.
|
__init__(self,
name,
includes=[],
excludes=[],
group=None)
Parameters |
|
|
|
addKey(self,
key,
positive=True)
Add the SMARTS pattern 'key' to the list of desired matches
(includes) if 'positive' is True, and to the list of unwanted matches
(excludes) if 'positive' is False. |
|
|
|
removeKey(self,
key)
Remove the SMARTS pattern 'key' from the wanted or unwanted matches
list. |
|
|
|
includes(self)
Return a list of wanted matches. |
|
|
|
excludes(self)
Return a list of unwanted matches. |
|
|
|
_expandIncludes(self,
inclist,
definitions,
masterlist)
For the provided list of Definitions 'inclist', expand any composite
definitions, using the contents of the 'definitions' list of
Definitions. |
|
|
|
_expandExcludes(self,
exclist,
definitions,
masterlist)
For the provided list of Definions 'exclist', expand any composite
definitions, using the contents of the 'definitions' list of
Definitions. |
|
|
|
expand(self,
definitions)
Generate a new Definition from the current one in which the includes
and excludes are expanded from the provided 'definitions' dictionary. |
|
|
|
__str__(self)
Return a standard string form of the Definition suitable for
filter/keys files. |
|
|