pub struct Article {
pub message_id: String,
pub segment_number: u32,
pub bytes: u64,
pub downloaded: bool,
pub data_begin: Option<u64>,
pub data_size: Option<u64>,
pub crc32: Option<u32>,
pub tried_servers: Vec<String>,
pub tries: u32,
}Expand description
A single NNTP article (segment of a file) — re-exported from the nzb-nntp crate.
A Usenet article segment to be downloaded.
Fields§
§message_id: StringMessage-ID (e.g., “abc123@example.com”)
segment_number: u32Segment number (1-based part number)
bytes: u64Encoded size in bytes
downloaded: boolHas this article been downloaded?
data_begin: Option<u64>Byte offset in the final file (set after yEnc decode)
data_size: Option<u64>Size of decoded data for this segment
crc32: Option<u32>CRC32 of decoded data
tried_servers: Vec<String>Servers that have been tried for this article
tries: u32Number of fetch attempts
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Article
impl<'de> Deserialize<'de> for Article
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<Article, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<Article, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for Article
impl Serialize for Article
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for Article
impl RefUnwindSafe for Article
impl Send for Article
impl Sync for Article
impl Unpin for Article
impl UnsafeUnpin for Article
impl UnwindSafe for Article
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,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more