molfoundry.ShortestPathConstraint#

class molfoundry.ShortestPathConstraint(source, target, op, length, maxLength=None)#

Bases: object

The shortest path from source to target has op length edges (GML constrainShortestPath).

With op ConstraintOp.Between its length lies in the inclusive range length to maxLength; maxLength is None for every other operator.

Parameters:
source: int#
target: int#
op: ConstraintOp#
length: int#
maxLength: int | None = None#
property children: Tuple[ConditionTrue | ConditionExists | ConditionNot | ConditionAnd | ConditionOr | AdjacencyConstraint | LabelAnyConstraint | ShortestPathConstraint | NoEdgeConstraint, ...]#