pub struct WaitingQueueBuilderwhere
WaitingSettings: Describe,{ /* private fields */ }Expand description
Builds a WaitingQueue from its settings, filled in layers, and the inputs it takes. build lists everything still missing at once.
Implementations§
Source§impl WaitingQueueBuilderwhere
Self: Holds<WaitingSettings>,
impl WaitingQueueBuilderwhere
Self: Holds<WaitingSettings>,
Sourcepub fn limits(self, value: impl Into<WaitingLimits>) -> Self
pub fn limits(self, value: impl Into<WaitingLimits>) -> Self
The bounds on entries. Default WaitingLimits::default.
Sourcepub fn ipv6_prefix(self, value: u8) -> Self
pub fn ipv6_prefix(self, value: u8) -> Self
The IPv6 prefix length sources are grouped by: 64, since one holder controls every address of a /64. 128 counts each address alone, which lets the holder of a subnet fill the queue; values above 128 are 128. IPv4 sources, IPv4-mapped IPv6 ones included, count per address.
Sourcepub fn when_full(self, value: impl Into<WhenFull>) -> Self
pub fn when_full(self, value: impl Into<WhenFull>) -> Self
What a source at its limit does with a newcomer. Default WhenFull::Refuse, so that
strangers sharing a source cannot flush those already waiting.
Sourcepub fn record_interval(self, value: impl Into<Duration>) -> Self
pub fn record_interval(self, value: impl Into<Duration>) -> Self
The least time between two new records from one source, each record being a synced write
a stranger can cause. Default DEFAULT_RECORD_INTERVAL; zero is no limit.
Source§impl WaitingQueueBuilderwhere
WaitingSettings: Describe,
impl WaitingQueueBuilderwhere
WaitingSettings: Describe,
Sourcepub fn fill(self, partial: Partial<WaitingSettings>) -> Self
pub fn fill(self, partial: Partial<WaitingSettings>) -> Self
Lays partial over what is set: only the keys it sets are taken, and the last
write of a key wins.
Sourcepub fn parts(self) -> Result<WaitingQueueParts, Missing>
pub fn parts(self) -> Result<WaitingQueueParts, Missing>
The parts: the settings built, every required input present and every optional input as given. A second terminal (one that builds a different value from the same parts) is written over this.
§Errors
Everything that is missing, at once: the same Missing
that build gives.
Sourcepub fn build(self) -> Result<WaitingQueue, Missing>
pub fn build(self) -> Result<WaitingQueue, Missing>
The built value, or everything that is missing: every required setting and every required input, at once.
§Errors
What is missing, or for a fallible build the error of the conversion.
Source§impl WaitingQueueBuilderwhere
WaitingSettings: Describe,
impl WaitingQueueBuilderwhere
WaitingSettings: Describe,
Sourcepub fn non_defaults(&self) -> Vec<NonDefault>
pub fn non_defaults(&self) -> Vec<NonDefault>
Every setting that differs from its default, as the builder would build it.
Trait Implementations§
Source§impl Check<WaitingQueueBuilder> for Profilewhere
WaitingSettings: Describe,
impl Check<WaitingQueueBuilder> for Profilewhere
WaitingSettings: Describe,
Source§fn check(&self, subject: &WaitingQueueBuilder, report: &mut Report)
fn check(&self, subject: &WaitingQueueBuilder, report: &mut Report)
subject, pushing a Finding per expectation.Source§impl Configured for WaitingQueueBuilderwhere
WaitingSettings: Describe,
impl Configured for WaitingQueueBuilderwhere
WaitingSettings: Describe,
Source§type Settings = WaitingSettings
type Settings = WaitingSettings
Source§fn configured(&self) -> &dyn Inspect
fn configured(&self) -> &dyn Inspect
Inspect].§fn non_defaults(&self) -> Vec<NonDefault>
fn non_defaults(&self) -> Vec<NonDefault>
Source§impl Debug for WaitingQueueBuilderwhere
WaitingSettings: Describe,
impl Debug for WaitingQueueBuilderwhere
WaitingSettings: Describe,
Source§impl From<Partial<WaitingSettings>> for WaitingQueueBuilderwhere
WaitingSettings: Describe,
impl From<Partial<WaitingSettings>> for WaitingQueueBuilderwhere
WaitingSettings: Describe,
Source§fn from(partial: Partial<WaitingSettings>) -> Self
fn from(partial: Partial<WaitingSettings>) -> Self
Source§impl Holds<WaitingSettings> for WaitingQueueBuilderwhere
WaitingSettings: Describe,
impl Holds<WaitingSettings> for WaitingQueueBuilderwhere
WaitingSettings: Describe,
Source§fn partial_mut(&mut self) -> &mut Partial<WaitingSettings>
fn partial_mut(&mut self) -> &mut Partial<WaitingSettings>
Auto Trait Implementations§
impl Freeze for WaitingQueueBuilderwhere
WaitingSettings: Sized,
impl RefUnwindSafe for WaitingQueueBuilderwhere
WaitingSettings: Sized,
impl Send for WaitingQueueBuilderwhere
WaitingSettings: Sized,
impl Sync for WaitingQueueBuilderwhere
WaitingSettings: Sized,
impl Unpin for WaitingQueueBuilderwhere
WaitingSettings: Sized,
impl UnsafeUnpin for WaitingQueueBuilderwhere
WaitingSettings: Sized,
impl UnwindSafe for WaitingQueueBuilderwhere
WaitingSettings: Sized,
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
Source§impl<__B> WaitingSettingsSetters for __Bwhere
__B: Holds<WaitingSettings>,
impl<__B> WaitingSettingsSetters for __Bwhere
__B: Holds<WaitingSettings>,
Source§fn limits(self, value: impl Into<WaitingLimits>) -> __B
fn limits(self, value: impl Into<WaitingLimits>) -> __B
WaitingLimits::default.Source§fn ipv6_prefix(self, value: u8) -> __B
fn ipv6_prefix(self, value: u8) -> __B
Source§fn when_full(self, value: impl Into<WhenFull>) -> __B
fn when_full(self, value: impl Into<WhenFull>) -> __B
WhenFull::Refuse, so that
strangers sharing a source cannot flush those already waiting.Source§fn record_interval(self, value: impl Into<Duration>) -> __B
fn record_interval(self, value: impl Into<Duration>) -> __B
DEFAULT_RECORD_INTERVAL; zero is no limit.