[][src]Struct sawtooth_sdk::processor::TransactionProcessor

pub struct TransactionProcessor<'a> { /* fields omitted */ }

Methods

impl<'a> TransactionProcessor<'a>[src]

pub fn new(endpoint: &str) -> TransactionProcessor[src]

TransactionProcessor is for communicating with a validator and routing transaction processing requests to a registered handler. It uses ZMQ and channels to handle requests concurrently.

pub fn add_handler(&mut self, handler: &'a dyn TransactionHandler)[src]

Adds a transaction family handler

Arguments

  • handler - the handler to be added

pub fn start(&mut self)[src]

Connects the transaction processor to a validator and starts listening for requests and routing them to an appropriate transaction handler.

Auto Trait Implementations

impl<'a> !RefUnwindSafe for TransactionProcessor<'a>

impl<'a> !Send for TransactionProcessor<'a>

impl<'a> !Sync for TransactionProcessor<'a>

impl<'a> Unpin for TransactionProcessor<'a>

impl<'a> !UnwindSafe for TransactionProcessor<'a>

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> SafeBorrow<T> for T where
    T: ?Sized

impl<T> Same<T> for T

type Output = T

Should always be Self

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.