Chemical Data Processing Library Python API - Version 1.1.1
Public Member Functions | Properties | List of all members
CDPL.ConfGen.TorsionRuleMatcher Class Reference
+ Inheritance diagram for CDPL.ConfGen.TorsionRuleMatcher:

Public Member Functions

None __init__ ()
 Initializes the TorsionRuleMatcher instance.
 
None __init__ (TorsionLibrary lib)
 Initializes the TorsionRuleMatcher instance. More...
 
None findUniqueMappingsOnly (bool unique)
 
bool findUniqueMappingsOnly ()
 
None findAllRuleMappings (bool all)
 
bool findAllRuleMappings ()
 
None stopAtFirstMatchingRule (bool stop)
 
bool stopAtFirstMatchingRule ()
 
None setTorsionLibrary (TorsionLibrary lib)
 
TorsionLibrary getTorsionLibrary ()
 
int getNumMatches ()
 Returns the number of stored torsion rule matches found by calls to findMatches(). More...
 
TorsionRuleMatch getMatch (int idx)
 Returns a reference to the stored torsion rule match object at index idx. More...
 
bool findMatches (Chem.Bond bond, Chem.MolecularGraph molgraph, bool append=False)
 
int getObjectID ()
 Returns the numeric identifier (ID) of the wrapped C++ class instance. More...
 
TorsionRuleMatch __getitem__ (int idx)
 
int __len__ ()
 

Properties

 objectID = property(getObjectID)
 
 numMatches = property(getNumMatches)
 
 uniqueMappingsOnly = property(findUniqueMappingsOnly, findUniqueMappingsOnly)
 
 allRuleMappings = property(findAllRuleMappings, findAllRuleMappings)
 
 onlyFirstMatchingRule = property(stopAtFirstMatchingRule, stopAtFirstMatchingRule)
 
 torsionLibrary = property(getTorsionLibrary, setTorsionLibrary)
 

Constructor & Destructor Documentation

◆ __init__()

None CDPL.ConfGen.TorsionRuleMatcher.__init__ ( TorsionLibrary  lib)

Initializes the TorsionRuleMatcher instance.

Parameters
lib

Member Function Documentation

◆ findUniqueMappingsOnly() [1/2]

None CDPL.ConfGen.TorsionRuleMatcher.findUniqueMappingsOnly ( bool  unique)
Parameters
unique

◆ findUniqueMappingsOnly() [2/2]

bool CDPL.ConfGen.TorsionRuleMatcher.findUniqueMappingsOnly ( )
Returns

◆ findAllRuleMappings() [1/2]

None CDPL.ConfGen.TorsionRuleMatcher.findAllRuleMappings ( bool  all)
Parameters
all

◆ findAllRuleMappings() [2/2]

bool CDPL.ConfGen.TorsionRuleMatcher.findAllRuleMappings ( )
Returns

◆ stopAtFirstMatchingRule() [1/2]

None CDPL.ConfGen.TorsionRuleMatcher.stopAtFirstMatchingRule ( bool  stop)
Parameters
stop

◆ stopAtFirstMatchingRule() [2/2]

bool CDPL.ConfGen.TorsionRuleMatcher.stopAtFirstMatchingRule ( )
Returns

◆ setTorsionLibrary()

None CDPL.ConfGen.TorsionRuleMatcher.setTorsionLibrary ( TorsionLibrary  lib)
Parameters
lib

◆ getTorsionLibrary()

TorsionLibrary CDPL.ConfGen.TorsionRuleMatcher.getTorsionLibrary ( )
Returns

◆ getNumMatches()

int CDPL.ConfGen.TorsionRuleMatcher.getNumMatches ( )

Returns the number of stored torsion rule matches found by calls to findMatches().

Returns
The number of stored torsion rule matches.

◆ getMatch()

TorsionRuleMatch CDPL.ConfGen.TorsionRuleMatcher.getMatch ( int  idx)

Returns a reference to the stored torsion rule match object at index idx.

Parameters
idxThe zero-based index of the torsion rule match object to return.
Returns
A reference to the torsion rule match object at index idx.
Exceptions
Base.IndexErrorif no torsion rule matches are available or idx is not in the range [0, getNumMatches() - 1].

◆ findMatches()

bool CDPL.ConfGen.TorsionRuleMatcher.findMatches ( Chem.Bond  bond,
Chem.MolecularGraph  molgraph,
bool   append = False 
)
Parameters
bond
molgraph
append
Returns

◆ getObjectID()

int CDPL.ConfGen.TorsionRuleMatcher.getObjectID ( )

Returns the numeric identifier (ID) of the wrapped C++ class instance.

Different Python TorsionRuleMatcher instances may reference the same underlying C++ class instance. The commonly used Python expression a is not b thus cannot tell reliably whether the two TorsionRuleMatcher instances a and b reference different C++ objects. The numeric identifier returned by this method allows to correctly implement such an identity test via the simple expression a.getObjectID() != b.getObjectID().

Returns
The numeric ID of the internally referenced C++ class instance.

◆ __getitem__()

TorsionRuleMatch CDPL.ConfGen.TorsionRuleMatcher.__getitem__ ( int  idx)
Parameters
idx
Returns

◆ __len__()

int CDPL.ConfGen.TorsionRuleMatcher.__len__ ( )
Returns