pub struct Engine {
pub state: Arc<StateStore>,
pub blocks: HistoryReader,
pub network_id: u32,
pub started: Instant,
pub confirmer: Option<Confirmer>,
pub quorum: Mutex<(u32, usize)>,
}Expand description
Reads validated ledgers, state and indexes.
Fields§
§state: Arc<StateStore>§blocks: HistoryReader§network_id: u32§started: Instant§confirmer: Option<Confirmer>Quorum confirmation, for evidence bundles (Proof API).
quorum: Mutex<(u32, usize)>Latest quorum for server_info: ledger and count.
Implementations§
Source§impl Engine
impl Engine
Source§impl Engine
impl Engine
Sourcepub fn proof_ledger(
&self,
p: &Map<String, Value>,
) -> Result<Map<String, Value>, RpcError>
pub fn proof_ledger( &self, p: &Map<String, Value>, ) -> Result<Map<String, Value>, RpcError>
Ledger bundle: proves that the header with this hash was validated by the network.
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for Engine
impl !RefUnwindSafe for Engine
impl !UnwindSafe for Engine
impl Send for Engine
impl Sync for Engine
impl Unpin for Engine
impl UnsafeUnpin for Engine
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Applies the layer to a service and wraps it in [
Layered].