pub struct GenerationRequest {
pub schedule_id: CycleScheduleId,
pub context: RuleContext,
pub look_ahead: u32,
pub actor: String,
pub confirmed: bool,
}Expand description
The explicit, confirmed intent to generate a schedule’s look-ahead (T018).
Every field is supplied and none is inferred: the schedule, the caller’s injected as-of date, how much look-ahead to apply, who asked, and that they confirmed. A surface builds one from a warning it showed the user; nothing constructs a confirmed one on the user’s behalf.
Fields§
§schedule_id: CycleScheduleIdThe schedule to generate for, by stable id.
context: RuleContextThe caller’s injected as-of date (and timezone policy). Never a clock.
look_ahead: u32How many candidates to apply, starting at ScheduleIndex::next_key.
0 requests nothing, which is the coherent reading WP03’s evaluator already
fixes: a schedule with no look-ahead has no candidate question to ask.
actor: StringWho confirmed the action — the caller’s audit context. Generation persists no History event, so this is reported, not stored.
confirmed: boolWhether the caller confirmed the action. An unconfirmed request is inert.
Implementations§
Source§impl GenerationRequest
impl GenerationRequest
Sourcepub fn new(
schedule_id: CycleScheduleId,
context: RuleContext,
look_ahead: u32,
actor: impl Into<String>,
) -> Self
pub fn new( schedule_id: CycleScheduleId, context: RuleContext, look_ahead: u32, actor: impl Into<String>, ) -> Self
A request that is not yet confirmed: naming a schedule is not consent, so a caller has to say so explicitly.
Trait Implementations§
Source§impl Clone for GenerationRequest
impl Clone for GenerationRequest
Source§impl Debug for GenerationRequest
impl Debug for GenerationRequest
impl Eq for GenerationRequest
Source§impl PartialEq for GenerationRequest
impl PartialEq for GenerationRequest
impl StructuralPartialEq for GenerationRequest
Auto Trait Implementations§
impl Freeze for GenerationRequest
impl RefUnwindSafe for GenerationRequest
impl Send for GenerationRequest
impl Sync for GenerationRequest
impl Unpin for GenerationRequest
impl UnsafeUnpin for GenerationRequest
impl UnwindSafe for GenerationRequest
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<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.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> ⓘ
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> ⓘ
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