def add_outgoing_edge(self, edge_type, target): """ ``add_outgoing_edge`` connects two flow graph nodes with an edge. :param BranchType edge_type: Type of edge to add :param FlowGraphNode target: Target node object """ core.BNAddFlowGraphNodeOutgoingEdge(self.handle, edge_type, target.handle)
def add_outgoing_edge(self, edge_type, target): """ ``add_outgoing_edge`` connects two flow graph nodes with an edge. :param BranchType edge_type: Type of edge to add :param FlowGraphNode target: Target node object """ if not target.is_valid_for_graph(self._graph): raise ValueError("Target of edge has not been added to the owning graph") core.BNAddFlowGraphNodeOutgoingEdge(self.handle, edge_type, target.handle)
def add_outgoing_edge(self, edge_type, target, style=None): """ ``add_outgoing_edge`` connects two flow graph nodes with an edge. :param BranchType edge_type: Type of edge to add :param FlowGraphNode target: Target node object :param EdgeStyle style: (optional) Styling for graph edge Branch Type must be set to UserDefinedBranch """ if not target.is_valid_for_graph(self._graph): raise ValueError( "Target of edge has not been added to the owning graph") if style is None: style = EdgeStyle() elif not isinstance(style, EdgeStyle): raise AttributeError("style must be of type EdgeStyle") core.BNAddFlowGraphNodeOutgoingEdge(self.handle, edge_type, target.handle, style._get_core_struct())