mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
Renamed the SocketServer module to 'socketserver'.
Merged revisions 63132 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r63132 | alexandre.vassalotti | 2008-05-11 22:11:22 -0400 (Sun, 11 May 2008) | 4 lines Updated all import statements to use the new socketserver module name. Renamed socketserver module in its own documentation. Renamed documentation references. ........
This commit is contained in:
parent
6f1e619b41
commit
ce261952e6
16 changed files with 63 additions and 64 deletions
|
@ -5,7 +5,7 @@ connect to the Idle process, which listens for the connection. Since Idle has
|
|||
has only one client per server, this was not a limitation.
|
||||
|
||||
+---------------------------------+ +-------------+
|
||||
| SocketServer.BaseRequestHandler | | SocketIO |
|
||||
| socketserver.BaseRequestHandler | | SocketIO |
|
||||
+---------------------------------+ +-------------+
|
||||
^ | register() |
|
||||
| | unregister()|
|
||||
|
@ -31,7 +31,7 @@ import sys
|
|||
import os
|
||||
import socket
|
||||
import select
|
||||
import SocketServer
|
||||
import socketserver
|
||||
import struct
|
||||
import pickle
|
||||
import threading
|
||||
|
@ -66,12 +66,12 @@ copyreg.pickle(types.CodeType, pickle_code, unpickle_code)
|
|||
BUFSIZE = 8*1024
|
||||
LOCALHOST = '127.0.0.1'
|
||||
|
||||
class RPCServer(SocketServer.TCPServer):
|
||||
class RPCServer(socketserver.TCPServer):
|
||||
|
||||
def __init__(self, addr, handlerclass=None):
|
||||
if handlerclass is None:
|
||||
handlerclass = RPCHandler
|
||||
SocketServer.TCPServer.__init__(self, addr, handlerclass)
|
||||
socketserver.TCPServer.__init__(self, addr, handlerclass)
|
||||
|
||||
def server_bind(self):
|
||||
"Override TCPServer method, no bind() phase for connecting entity"
|
||||
|
@ -492,7 +492,7 @@ class RemoteProxy(object):
|
|||
def __init__(self, oid):
|
||||
self.oid = oid
|
||||
|
||||
class RPCHandler(SocketServer.BaseRequestHandler, SocketIO):
|
||||
class RPCHandler(socketserver.BaseRequestHandler, SocketIO):
|
||||
|
||||
debugging = False
|
||||
location = "#S" # Server
|
||||
|
@ -500,10 +500,10 @@ class RPCHandler(SocketServer.BaseRequestHandler, SocketIO):
|
|||
def __init__(self, sock, addr, svr):
|
||||
svr.current_handler = self ## cgt xxx
|
||||
SocketIO.__init__(self, sock)
|
||||
SocketServer.BaseRequestHandler.__init__(self, sock, addr, svr)
|
||||
socketserver.BaseRequestHandler.__init__(self, sock, addr, svr)
|
||||
|
||||
def handle(self):
|
||||
"handle() method required by SocketServer"
|
||||
"handle() method required by socketserver"
|
||||
self.mainloop()
|
||||
|
||||
def get_remote_proxy(self, oid):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue