Struct tor_netdoc::doc::netstatus::CommonHeader
source · [−]#[non_exhaustive]pub struct CommonHeader {
pub flavor: ConsensusFlavor,
pub lifetime: Lifetime,
pub client_versions: Vec<String>,
pub relay_versions: Vec<String>,
pub client_protos: ProtoStatus,
pub relay_protos: ProtoStatus,
pub params: NetParams<i32>,
pub voting_delay: Option<(u32, u32)>,
}
Expand description
Parts of the networkstatus header that are present in every networkstatus.
NOTE: this type is separate from the header parts that are only in votes or only in consensuses, even though we don’t implement votes yet.
Fields (Non-exhaustive)
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.flavor: ConsensusFlavor
What kind of consensus document is this? Absent in votes and in ns-flavored consensuses.
lifetime: Lifetime
Over what time is this consensus valid? (For votes, this is the time over which the voted-upon consensus should be valid.)
client_versions: Vec<String>
List of recommended Tor client versions.
relay_versions: Vec<String>
List of recommended Tor relay versions.
client_protos: ProtoStatus
Lists of recommended and required subprotocol versions for clients
relay_protos: ProtoStatus
Lists of recommended and required subprotocol versions for relays
params: NetParams<i32>
Declared parameters for tunable settings about how to the network should operator. Some of these adjust timeouts and whatnot; some features things on and off.
voting_delay: Option<(u32, u32)>
How long in seconds should voters wait for votes and signatures (respectively) to propagate?
Trait Implementations
sourceimpl Clone for CommonHeader
impl Clone for CommonHeader
sourcefn clone(&self) -> CommonHeader
fn clone(&self) -> CommonHeader
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl RefUnwindSafe for CommonHeader
impl Send for CommonHeader
impl Sync for CommonHeader
impl Unpin for CommonHeader
impl UnwindSafe for CommonHeader
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more