pub struct StatisticalComputationEngine { /* private fields */ }Expand description
Statistical computation engine
Implementations§
Source§impl StatisticalComputationEngine
impl StatisticalComputationEngine
pub fn new() -> Self
pub fn initialize(&mut self) -> Result<(), StatisticalError>
Sourcepub fn add_computation_unit(&mut self, unit: StatisticalComputationUnit)
pub fn add_computation_unit(&mut self, unit: StatisticalComputationUnit)
Register a computation unit that can execute statistical operations.
Sourcepub fn computation_units(&self) -> &[StatisticalComputationUnit]
pub fn computation_units(&self) -> &[StatisticalComputationUnit]
Returns the list of registered computation units.
Sourcepub fn get_computation_unit(
&self,
unit_id: &str,
) -> Option<&StatisticalComputationUnit>
pub fn get_computation_unit( &self, unit_id: &str, ) -> Option<&StatisticalComputationUnit>
Look up a computation unit by id.
Sourcepub fn computation_unit_count(&self) -> usize
pub fn computation_unit_count(&self) -> usize
Returns the number of registered computation units.
Sourcepub fn enqueue_operation(&mut self, operation: StatisticalOperation)
pub fn enqueue_operation(&mut self, operation: StatisticalOperation)
Enqueue a statistical operation for later execution.
Sourcepub fn operation_queue(&self) -> &[StatisticalOperation]
pub fn operation_queue(&self) -> &[StatisticalOperation]
Returns the operations currently waiting in the queue.
Sourcepub fn drain_operation_queue(&mut self) -> Vec<StatisticalOperation>
pub fn drain_operation_queue(&mut self) -> Vec<StatisticalOperation>
Drain all queued operations, returning them in submission order.
Sourcepub fn queued_operation_count(&self) -> usize
pub fn queued_operation_count(&self) -> usize
Returns the number of operations currently in the queue.
Sourcepub fn scheduler(&self) -> &StatisticalScheduler
pub fn scheduler(&self) -> &StatisticalScheduler
Returns a reference to the scheduler.
Sourcepub fn scheduler_mut(&mut self) -> &mut StatisticalScheduler
pub fn scheduler_mut(&mut self) -> &mut StatisticalScheduler
Returns a mutable reference to the scheduler.
Auto Trait Implementations§
impl Freeze for StatisticalComputationEngine
impl RefUnwindSafe for StatisticalComputationEngine
impl Send for StatisticalComputationEngine
impl Sync for StatisticalComputationEngine
impl Unpin for StatisticalComputationEngine
impl UnsafeUnpin for StatisticalComputationEngine
impl UnwindSafe for StatisticalComputationEngine
Blanket Implementations§
§impl<S, A> Aggregate<Result<S, Error>> for Awhere
A: Aggregate<S>,
impl<S, A> Aggregate<Result<S, Error>> for Awhere
A: Aggregate<S>,
Aggregate shares in an MPC protocol.
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<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more