Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(4)  |  Call(0)  |  Derive(0)  |  Import(4)

src/p/y/pyroute2-0.2.8/pyroute2/netlink/iproute.py   pyroute2(Download)
from pyroute2.netlink import NLM_F_EXCL
from pyroute2.netlink.client import Netlink
from pyroute2.netlink.generic import NETLINK_ROUTE
from pyroute2.netlink.rtnl.tcmsg import tcmsg
from pyroute2.netlink.rtnl.tcmsg import get_htb_parameters
    def __init__(self):
        NetlinkSocket.__init__(self, NETLINK_ROUTE)
        self.marshal = MarshalRtnl()
 
    def bind(self, groups=RTNL_GROUPS):
    '''
    marshal = MarshalRtnl
    family = NETLINK_ROUTE
    groups = RTNL_GROUPS
 

src/p/y/pyroute2-HEAD/pyroute2/netlink/iproute.py   pyroute2(Download)
from pyroute2.netlink import NLM_F_EXCL
from pyroute2.netlink.client import Netlink
from pyroute2.netlink.generic import NETLINK_ROUTE
from pyroute2.netlink.rtnl.tcmsg import tcmsg
from pyroute2.netlink.rtnl.tcmsg import get_htb_parameters
    def __init__(self):
        NetlinkSocket.__init__(self, NETLINK_ROUTE)
        self.marshal = MarshalRtnl()
 
    def bind(self, groups=RTNL_GROUPS):
    '''
    marshal = MarshalRtnl
    family = NETLINK_ROUTE
    groups = RTNL_GROUPS
 

src/l/n/lnst-1/lnst/Common/NetUtils.py   lnst(Download)
from pyroute2.netlink import NLMSG_DONE
from pyroute2.netlink import NLMSG_ERROR
from pyroute2.netlink.generic import NETLINK_ROUTE
from pyroute2.netlink.iproute import MarshalRtnl
from pyroute2.netlink.iproute import RTM_GETLINK
def scan_netdevs():
    scan = []
    nl_socket = NetlinkSocket(family=NETLINK_ROUTE)
    msg = ifinfmsg()
    msg["family"] = socket.AF_UNSPEC

src/l/n/lnst-1/lnst/Slave/NetTestSlave.py   lnst(Download)
#TODO this is temporary, until python-pyroute2 package is updated
from pyroute2.netlink import NetlinkSocket
from pyroute2.netlink.generic import NETLINK_ROUTE
 
RTNLGRP_LINK = 0x1
        self._log_ctl = log_ctl
 
        self._nl_socket = NetlinkSocket(family=NETLINK_ROUTE)
        self._nl_socket.bind(RTNL_GROUPS)
        self._server_handler.add_connection('netlink', self._nl_socket)