(self, dst, gw=None, dev=None)
return (prefix, plen, gw, dev, ifaddr)
Internal function : create a route for 'dst' via 'gw'.
Internal function : create a route for 'dst' via 'gw'.
Internal function : create a route for dst via gw .
def make_route(self, dst, gw=None, dev=None):
        """Internal function : create a route for 'dst' via 'gw'.
        """
        prefix, plen = (dst.split("/")+["128"])[:2]
        plen = int(plen)

        if gw is None:
            gw = "::"
        if dev is None:
            dev, ifaddr, x = self.route(gw)
        else:
            # TODO: do better than that
            # replace that unique address by the list of all addresses
            lifaddr = in6_getifaddr()             
            devaddrs = filter(lambda x: x[2] == dev, lifaddr)
            ifaddr = construct_source_candidate_set(prefix, plen, devaddrs, LOOPBACK_NAME)

        return (prefix, plen, gw, dev, ifaddr)
def make_route ( self , dst , gw = None , dev = None ) : prefix , plen = ( dst . split ( "/" ) + [ "128" ] ) [ : 2 ] plen = int ( plen ) if gw is None : gw = "::" if dev is None : dev , ifaddr , x = self . route ( gw ) else : # TODO: do better than that # replace that unique address by the list of all addresses lifaddr = in6_getifaddr ( ) devaddrs = filter ( lambda x : x [ 2 ] == dev , lifaddr ) ifaddr = construct_source_candidate_set ( prefix , plen , devaddrs , LOOPBACK_NAME ) return ( prefix , plen , gw , dev , ifaddr )