pub enum HashJob {
Data {
piece: u32,
expected: Id20,
generation: u64,
data: Vec<u8>,
result_tx: Sender<HashResult>,
},
Streaming {
piece: u32,
expected: Id20,
generation: u64,
info_hash: Id20,
backend: Arc<dyn DiskIoBackend>,
result_tx: Sender<HashResult>,
},
}Expand description
Job submitted to the hash pool.
Variants§
Data
Pre-read piece data (original path).
Fields
§
result_tx: Sender<HashResult>Per-torrent result sender.
Streaming
Streaming verify via backend (M101 — no full-piece alloc).
Fields
§
backend: Arc<dyn DiskIoBackend>Disk I/O backend for streaming verification.
§
result_tx: Sender<HashResult>Per-torrent result sender.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for HashJob
impl !RefUnwindSafe for HashJob
impl Send for HashJob
impl Sync for HashJob
impl Unpin for HashJob
impl UnsafeUnpin for HashJob
impl !UnwindSafe for HashJob
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