pub enum Sv2ClientKind {
Miner,
TranslatorProxy,
Unknown,
}Expand description
Kind of SV2 downstream client connected to this node.
Variants§
Miner
A mining device connected directly as an SV2 downstream client.
TranslatorProxy
A Translator Proxy connected as the SV2 client for one or more SV1 miners.
Unknown
The downstream client type could not be inferred from SetupConnection metadata.
Implementations§
Source§impl Sv2ClientKind
impl Sv2ClientKind
Sourcepub fn from_setup_connection(vendor: &str, hardware_version: &str) -> Self
pub fn from_setup_connection(vendor: &str, hardware_version: &str) -> Self
Infer the downstream client kind from SetupConnection vendor and hardware version fields.
Trait Implementations§
Source§impl Clone for Sv2ClientKind
impl Clone for Sv2ClientKind
Source§fn clone(&self) -> Sv2ClientKind
fn clone(&self) -> Sv2ClientKind
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl ComposeSchema for Sv2ClientKind
impl ComposeSchema for Sv2ClientKind
impl Copy for Sv2ClientKind
Source§impl Debug for Sv2ClientKind
impl Debug for Sv2ClientKind
Source§impl Default for Sv2ClientKind
impl Default for Sv2ClientKind
Source§impl<'de> Deserialize<'de> for Sv2ClientKind
impl<'de> Deserialize<'de> for Sv2ClientKind
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Sv2ClientKind
Source§impl PartialEq for Sv2ClientKind
impl PartialEq for Sv2ClientKind
Source§impl Serialize for Sv2ClientKind
impl Serialize for Sv2ClientKind
impl StructuralPartialEq for Sv2ClientKind
Auto Trait Implementations§
impl Freeze for Sv2ClientKind
impl RefUnwindSafe for Sv2ClientKind
impl Send for Sv2ClientKind
impl Sync for Sv2ClientKind
impl Unpin for Sv2ClientKind
impl UnsafeUnpin for Sv2ClientKind
impl UnwindSafe for Sv2ClientKind
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.