| Crates.io | base_core_socialist_values |
| lib.rs | base_core_socialist_values |
| version | 0.3.4 |
| created_at | 2019-04-13 06:52:41.393999+00 |
| updated_at | 2019-04-15 14:36:24.938516+00 |
| description | Encode and decode with BCSV (base core socialist values) |
| homepage | |
| repository | https://github.com/QSCTech/BaseCoreSocialistValues |
| max_upload_size | |
| id | 127620 |
| size | 13,046 |
富强、民主、文明、和谐
自由、平等、公正、法治
爱国、敬业、诚信、友善
Let the evil man in the middle know WHAT WE BELIEVE IN :)
EncoderImplemented Write
// examples/encoder.rs
use base_core_socialist_values::Encoder;
use std::io::{self, stdout, stdin};
fn main() -> io::Result<()> {
let mut reader = stdin();
let mut writer = stdout();
io::copy(&mut reader, &mut Encoder::new(&mut writer))?;
Ok(())
}
cargo run --example encoder
run, enter and Ctrl D (there is buffer in stdout)
DecoderImplemented Write
// examples/decoder.rs
use base_core_socialist_values::Decoder;
use std::io::{self, stdout, stdin};
fn main() -> io::Result<()> {
let mut reader = stdin();
let mut writer = stdout();
io::copy(&mut reader, &mut Decoder::new(&mut writer))?;
Ok(())
}
cargo run --example decoder
run, enter and Ctrl D (there is buffer in stdout)