Struct template_distribution_sv2::SubmitSolution [−][src]
pub struct SubmitSolution<'decoder> { pub template_id: u64, pub version: u32, pub header_timestamp: u32, pub header_nonce: u32, pub coinbase_tx: B064K<'decoder>, }
Expand description
SubmitSolution (Client -> Server)
Upon finding a coinbase transaction/nonce pair which double-SHA256 hashes at or below
[crate::SetNewPrevHash.target
], the client MUST immediately send this message, and the server
MUST then immediately construct the corresponding full block and attempt to propagate it to
the Bitcoin network.
Fields
template_id: u64
The template_id field as it appeared in NewTemplate.
version: u32
The version field in the block header. Bits not defined by [BIP320](TODO link) as additional nonce MUST be the same as they appear in the [NewWork](TODO link) message, other bits may be set to any value.
header_timestamp: u32
The nTime field in the block header. This MUST be greater than or equal
to the header_timestamp field in the latest crate::SetNewPrevHash
message
and lower than or equal to that value plus the number of seconds since
the receipt of that message.
header_nonce: u32
The nonce field in the header.
coinbase_tx: B064K<'decoder>
The full serialized coinbase transaction, meeting all the requirements of the NewWork message, above.
Trait Implementations
fn from_bytes(data: &'a mut [u8]) -> Result<Self, Error>
fn from_reader(reader: &mut impl Read) -> Result<Self, Error>
Performs the conversion.
Performs the conversion.
Auto Trait Implementations
impl<'decoder> RefUnwindSafe for SubmitSolution<'decoder>
impl<'decoder> Send for SubmitSolution<'decoder>
impl<'decoder> Sync for SubmitSolution<'decoder>
impl<'decoder> Unpin for SubmitSolution<'decoder>
impl<'decoder> !UnwindSafe for SubmitSolution<'decoder>
Blanket Implementations
Mutably borrows from an owned value. Read more
impl<'a, T> Encodable for T where
T: Into<EncodableField<'a>>,
impl<'a, T> Encodable for T where
T: Into<EncodableField<'a>>,