class SocketType(object):
def bind(self, address): # real signature unknown; restored from __doc__
"""
bind(address)
Bind the socket to a local address. For IP sockets, the address is a
pair (host, port); the host must refer to the local host. For raw packet
sockets the address is a tuple (ifname, proto [,pkttype [,hatype]])
"""
pass
def close(self): # real signature unknown; restored from __doc__
"""
close()
Close the socket. It cannot be used after this call.
"""
pass
这个模块是用C实现的,没有Python源码。
你要看c的源码的话:https://github.com/python/cpy...