Struct czmq::ZCert [] [src]

pub struct ZCert { /* fields omitted */ }

Methods

impl ZCert
[src]

Encode certificate metadata into ZMQ wire format.

let cert = ZCert::new().unwrap();
cert.set_meta("key", "value");

let encoded = cert.encode_meta();
let frame = ZFrame::new(&encoded).unwrap();
frame.send(&mut sock, None).unwrap();

Decode and set certificate metadata from ZMQ wire format.

let frame = ZFrame::recv(&mut sock).unwrap();
let encoded = match frame.data().unwrap() {
    Ok(str) => str.into_bytes(),
    Err(bytes) => bytes,
};

let cert = ZCert::new().unwrap();
cert.decode_meta(&encoded).unwrap();

Trait Implementations

impl Debug for ZCert
[src]

Formats the value using the given formatter.

impl Eq for ZCert
[src]

impl Send for ZCert
[src]

impl Sync for ZCert
[src]

impl Drop for ZCert
[src]

A method called when the value goes out of scope. Read more

impl PartialEq for ZCert
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl RawInterface<zcert_t> for ZCert
[src]