[][src]Struct zkinterface::reading::Messages

pub struct Messages {
    pub messages: Vec<Vec<u8>>,
    pub first_id: u64,
}

Collect buffers waiting to be read.

Fields

messages: Vec<Vec<u8>>first_id: u64

Implementations

impl Messages[src]

pub fn new() -> Messages[src]

pub fn new_filtered(first_id: u64) -> Messages[src]

Collect messages. Methods will filter out irrelevant variables. first_id: The first variable ID to consider in received messages. Variables with lower IDs are ignored.

pub fn push_message(&mut self, buf: Vec<u8>) -> Result<()>[src]

pub fn read_from(&mut self, reader: &mut impl Read) -> Result<()>[src]

pub fn read_file(&mut self, path: impl AsRef<Path>) -> Result<()>[src]

pub fn first_circuit(&self) -> Option<Circuit>[src]

pub fn last_circuit(&self) -> Option<Circuit>[src]

pub fn circuits(&self) -> Vec<Circuit>[src]

pub fn connection_variables(&self) -> Option<Vec<Variable>>[src]

pub fn private_variables(&self) -> Option<Vec<Variable>>[src]

impl Messages[src]

pub fn iter_constraints(&self) -> R1CSIterator

Important traits for R1CSIterator<'a>

impl<'a> Iterator for R1CSIterator<'a> type Item = Constraint<'a>;
[src]

impl Messages[src]

pub fn iter_witness(&self) -> WitnessIterator

Important traits for WitnessIterator<'a>

impl<'a> Iterator for WitnessIterator<'a> type Item = Variable<'a>;
[src]

Trait Implementations

impl Clone for Messages[src]

impl Debug for Messages[src]

impl<'_> From<&'_ Messages> for MessagesOwned[src]

fn from(messages: &Messages) -> MessagesOwned[src]

Convert from Flatbuffers messages to owned structure.

impl<'a> IntoIterator for &'a Messages[src]

type Item = Root<'a>

The type of the elements being iterated over.

type IntoIter = MessageIterator<'a>

Which kind of iterator are we turning this into?

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.