(self, node, hyperedge)
Link given node and hyperedge.

        @type  node: node
        @param node: Node.

        @type  hyperedge: node
        @param hyperedge: Hyperedge.
Link given node and hyperedge.
Link given node and hyperedge .
def link(self, node, hyperedge):
        """
        Link given node and hyperedge.

        @type  node: node
        @param node: Node.

        @type  hyperedge: node
        @param hyperedge: Hyperedge.
        """
        if (hyperedge not in self.node_links[node]):
            self.edge_links[hyperedge].append(node)
            self.node_links[node].append(hyperedge)
            self.graph.add_edge(((node,'n'), (hyperedge,'h')))
        else:
            raise AdditionError("Link (%s, %s) already in graph" % (node, hyperedge))
def link ( self , node , hyperedge ) : if ( hyperedge not in self . node_links [ node ] ) : self . edge_links [ hyperedge ] . append ( node ) self . node_links [ node ] . append ( hyperedge ) self . graph . add_edge ( ( ( node , 'n' ) , ( hyperedge , 'h' ) ) ) else : raise AdditionError ( "Link (%s, %s) already in graph" % ( node , hyperedge ) )