rust-zmq 0,0,0,1 travis-ci

Rust zeromq bindings.

3 years after

Rust ZeroMQ bindings.

Travis Build Status Appveyor Build status Coverage Status Apache 2.0 licensed MIT licensed crates.io

Installation

rust-zmq uses cargo to install. Users should add this to their Cargo.toml file:

[dependencies.zmq]
git = "https://github.com/erickt/rust-zmq.git"

Install for developers:

% git clone https://github.com/erickt/rust-zmq
% cd rust-zmq
% cargo build

Usage

rust-zmq is a pretty straight forward port of the C API into Rust:

extern crate zmq;

fn main() {
    let mut ctx = zmq::Context::new();

    let mut socket = match ctx.socket(zmq::REQ) {
      Ok(socket) => { socket },
      Err(e) => { panic!(e) }
    };

    match socket.connect("tcp://127.0.0.1:1234") {
      Ok(()) => (),
      Err(e) => panic!(e)
    }

    match socket.send_str("hello world!", 0) {
      Ok(()) => (),
      Err(e) => panic!(e)
    }
}

You can find more usage examples in https://github.com/erickt/rust-zmq/tree/master/examples.

Related Repositories

free-programming-books-zh_CN

free-programming-books-zh_CN

:books: 免费的计算机编程类中文书籍,欢迎投稿 ...

awesome-ocaml

awesome-ocaml

A curated collection of awesome OCaml tools, frameworks, libraries and articles. ...

LightQ

LightQ

...

zmq.rs

zmq.rs

A native implementation of ØMQ in Rust ...

FFI-Platypus

FFI-Platypus

Write Perl bindings to non-Perl libraries with FFI. No XS required. ...


Top Contributors

erickt jedisct1 cmr drbawb petehayes102 dcbishop reset buster dwrensha cristicbz bombela smvv belisarius222 thomascellerier dougroyal huonw serprex apoelstra brson frewsxcv dflemstr Geal reem blaenk influenza musitdev

Releases

-   v0.7.0 zip tar
-   v0.6.0 zip tar
-   v0.2 zip tar
-   v0.1 zip tar
-   0.6.7 zip tar
-   0.6.6 zip tar
-   0.6.5 zip tar
-   0.6.4 zip tar
-   0.6.3 zip tar
-   0.6.2 zip tar
-   0.6.1 zip tar