(self, host: str, port: int)
| 19 | DELAY = 0.6 |
| 20 | |
| 21 | def __init__(self, host: str, port: int): |
| 22 | sock = socket.socket(socket.AF_INET,socket.SOCK_STREAM) |
| 23 | txtf = sock.makefile('w') |
| 24 | |
| 25 | sock.connect((host, port)) |
| 26 | |
| 27 | self.__sock = sock |
| 28 | self.__file = txtf |
| 29 | |
| 30 | def __enter__(self): |
| 31 | return self |