[−][src]Struct stratum_client::client::StratumClient
Fields
write_half: Arc<Mutex<WriteHalf<TcpStream>>>read_half: Arc<Mutex<BufReader<ReadHalf<TcpStream>>>>config: Arc<ClientConfig<SP, PP>>Methods
impl<PP, SP> StratumClient<PP, SP> where
PP: PoolParams + Serialize + for<'de> Deserialize<'de> + Sync + Send + Debug + Clone + 'static,
SP: StratumParams + Serialize + for<'de> Deserialize<'de> + Sync + Send + Debug + Clone + 'static, [src]
PP: PoolParams + Serialize + for<'de> Deserialize<'de> + Sync + Send + Debug + Clone + 'static,
SP: StratumParams + Serialize + for<'de> Deserialize<'de> + Sync + Send + Debug + Clone + 'static,
pub async fn new(config: ClientConfig<SP, PP>) -> Result<Self>[src]
pub async fn init_connection<'_>(&'_ self) -> Result<()>[src]
pub fn run(&self) -> Result<()>[src]
pub async fn start<'_>(&'_ self) -> Result<()>[src]
pub async fn next_message<'_>(&'_ self) -> Result<PoolPacket<PP, SP>>[src]
pub async fn authorize<'_>(&'_ self) -> Result<bool>[src]
pub async fn subscribe<'_>(&'_ self) -> Result<()>[src]
pub async fn handle_authorize_return<'_, '_>(
&'_ self,
_auth: &'_ PP::Authorized
) -> Result<()>[src]
&'_ self,
_auth: &'_ PP::Authorized
) -> Result<()>
pub async fn submit<'_>(&'_ self, share: SP::Submit) -> Result<()>[src]
pub async fn is_new_work<'_>(&'_ self) -> bool[src]
pub async fn get_difficulty<'_>(&'_ self) -> f64[src]
pub async fn get_work<'_>(&'_ self) -> Option<SP::Notify>[src]
pub async fn wait_for_work<'_>(&'_ self) -> Result<()>[src]
Trait Implementations
impl<PP: Clone, SP: Clone> Clone for StratumClient<PP, SP> where
PP: PoolParams,
SP: StratumParams,
SP::Notify: Clone, [src]
PP: PoolParams,
SP: StratumParams,
SP::Notify: Clone,
fn clone(&self) -> StratumClient<PP, SP>[src]
fn clone_from(&mut self, source: &Self)1.0.0[src]
impl<PP: Debug, SP: Debug> Debug for StratumClient<PP, SP> where
PP: PoolParams,
SP: StratumParams,
SP::Notify: Debug, [src]
PP: PoolParams,
SP: StratumParams,
SP::Notify: Debug,
Auto Trait Implementations
impl<PP, SP> !RefUnwindSafe for StratumClient<PP, SP>
impl<PP, SP> Send for StratumClient<PP, SP> where
<PP as PoolParams>::Authorize: Send + Sync,
<SP as StratumParams>::Notify: Send,
<SP as StratumParams>::Submit: Send,
<SP as StratumParams>::Subscribe: Send + Sync,
<PP as PoolParams>::Authorize: Send + Sync,
<SP as StratumParams>::Notify: Send,
<SP as StratumParams>::Submit: Send,
<SP as StratumParams>::Subscribe: Send + Sync,
impl<PP, SP> Sync for StratumClient<PP, SP> where
<PP as PoolParams>::Authorize: Send + Sync,
<SP as StratumParams>::Notify: Send,
<SP as StratumParams>::Submit: Send,
<SP as StratumParams>::Subscribe: Send + Sync,
<PP as PoolParams>::Authorize: Send + Sync,
<SP as StratumParams>::Notify: Send,
<SP as StratumParams>::Submit: Send,
<SP as StratumParams>::Subscribe: Send + Sync,
impl<PP, SP> Unpin for StratumClient<PP, SP>
impl<PP, SP> !UnwindSafe for StratumClient<PP, SP>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone, [src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T[src]
fn clone_into(&self, target: &mut T)[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,