chanmgr: Extend doc comments for Dormancy

Prompted by
  https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/657#note_2825962
This commit is contained in:
Ian Jackson 2022-08-04 14:30:13 +01:00
parent e5396a35c8
commit b5176a700b
1 changed files with 6 additions and 0 deletions

View File

@ -110,14 +110,20 @@ pub enum ChanProvenance {
}
/// Dormancy state, as far as the channel manager is concerned
///
/// This is usually derived in higher layers from `arti_client::DormantMode`.
#[non_exhaustive]
#[derive(Debug, Copy, Clone, Eq, PartialEq, Educe)]
#[educe(Default)]
pub enum Dormancy {
/// Not dormant
///
/// Channels will operate normally.
#[educe(Default)]
Active,
/// Totally dormant
///
/// Channels will not perform any spontaneous activity (eg, netflow padding)
Dormant,
}