pub struct ComposableExecutionEngine { /* private fields */ }Expand description
Composable execution engine that can be configured with different strategies
Implementations§
Source§impl ComposableExecutionEngine
impl ComposableExecutionEngine
Sourcepub fn new(config: ExecutionEngineConfig) -> SklResult<Self>
pub fn new(config: ExecutionEngineConfig) -> SklResult<Self>
Create a new execution engine with the given configuration
Sourcepub fn register_strategy(&mut self, strategy: Box<dyn ExecutionStrategy>)
pub fn register_strategy(&mut self, strategy: Box<dyn ExecutionStrategy>)
Register a new execution strategy
Sourcepub fn execute_task(
&mut self,
task: Box<dyn ExecutableTask>,
) -> SklResult<ExecutionResult>
pub fn execute_task( &mut self, task: Box<dyn ExecutableTask>, ) -> SklResult<ExecutionResult>
Execute a task using the best available strategy
Sourcepub fn metrics(&self) -> ExecutionMetrics
pub fn metrics(&self) -> ExecutionMetrics
Get current execution metrics
Sourcepub fn config(&self) -> &ExecutionEngineConfig
pub fn config(&self) -> &ExecutionEngineConfig
Get engine configuration
Auto Trait Implementations§
impl Freeze for ComposableExecutionEngine
impl !RefUnwindSafe for ComposableExecutionEngine
impl Send for ComposableExecutionEngine
impl Sync for ComposableExecutionEngine
impl Unpin for ComposableExecutionEngine
impl !UnwindSafe for ComposableExecutionEngine
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
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