Extension providing a basic networking protcol implementations as a Python module using mainly C-Extenstions.
Project description
# networkinglib Python Networking Module
## How to use
### TCP Client #### Opening socket and connecting to server `Python from networkinglib import tcp socket = tcp.connect('127.0.0.1', 7777) if not socket: print("Could not connect!") `
#### Sending packet `Python socket.send("Hello Server!") `
#### Receiving Packets `Python print(socket.receive()) `
#### Closing connection `Python socket.close() `
### UDP Client #### Opening socket `Python from networkinglib import udp socket = udp.open() if not socket: print("An unexpected error occured!") `
#### Sending packet `Python socket.send("Hello Server!", "127.0.0.1", 7777) # or socket.send("Hello Server!", "127.0.0.1:7777") `
#### Receiving Packets `Python print(socket.receive()) `
#### Closing connection `Python socket.close() `
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for networkinglib-0.2.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fc39c649fed3259de42fc81a3b06744a252e9faf0680c935b0f94945860dd50a |
|
MD5 | 50ae05d6047f952a836029cc62af5ccd |
|
BLAKE2b-256 | 07fe9cc4f0505e21a2364e13f499195d919435ff23ef7c9c841700131dba3583 |