Hot-keys on this page
r m x p toggle line displays
j k next/prev highlighted chunk
0 (zero) top of page
1 (one) first highlighted chunk
1import urllib.parse
4class ServerIf:
5 def __init__(self, addr: str, params: dict = {}):
6 self.addr = addr # URL or host:port
7 self.params = params # options
8 try:
9 if addr.find("/") == -1:
10 addr = "//" + addr
11 self.addr_parsed = urllib.parse.urlsplit(addr)
12 except Exception:
13 pass
15 def serve(self, dispatcher):
16 pass