pub struct MiningManager { /* private fields */ }Expand description
AI Mining Manager - handles compute job execution and rewards
Implementations§
Source§impl MiningManager
impl MiningManager
pub fn new(config: MiningConfig) -> Self
Sourcepub async fn start_mining(&self) -> Result<(), Box<dyn Error>>
pub async fn start_mining(&self) -> Result<(), Box<dyn Error>>
Start mining on the configured network
Sourcepub async fn execute_job(
&self,
job: ComputeJob,
) -> Result<Vec<u8>, Box<dyn Error>>
pub async fn execute_job( &self, job: ComputeJob, ) -> Result<Vec<u8>, Box<dyn Error>>
Execute a compute job
Sourcepub async fn get_stats(&self) -> MiningStats
pub async fn get_stats(&self) -> MiningStats
Get mining statistics
Auto Trait Implementations§
impl Freeze for MiningManager
impl !RefUnwindSafe for MiningManager
impl Send for MiningManager
impl Sync for MiningManager
impl Unpin for MiningManager
impl UnsafeUnpin for MiningManager
impl !UnwindSafe for MiningManager
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