| Crates.io | susy-tokio-ipc |
| lib.rs | susy-tokio-ipc |
| version | 0.1.0 |
| created_at | 2019-03-23 00:49:15.001386+00 |
| updated_at | 2019-03-23 00:49:15.001386+00 |
| description | Interprocess communication library for tokio. |
| homepage | https://github.com/susytech/susy-tokio-ipc |
| repository | https://github.com/susytech/susy-tokio-ipc |
| max_upload_size | |
| id | 123212 |
| size | 38,584 |
This crate abstracts interprocess transport for UNIX/Windows. On UNIX it utilizes unix sockets (tokio_uds crate) and named pipe on windows (experimental tokio-named-pipes crate).
Endpoint is transport-agnostic interface for incoming connections:
let endpoint = Endpoint::new(endpoint_addr, handle).unwrap();
endpoint.incoming().for_each(|_| println!("Connection received!"));
And IpcStream is transport-agnostic io:
let endpoint = Endpoint::new(endpoint_addr, handle).unwrap();
endpoint.incoming().for_each(|(ipc_stream: IpcStream, _)| io::write_all(ipc_stream, b"Hello!"));
susy-tokio-ipc is primarily distributed under the terms of both the MIT
license and the Apache License (Version 2.0), with portions covered by various
BSD-like licenses.
See LICENSE-APACHE, and LICENSE-MIT for details.