pub struct GradientCapturePlan { /* private fields */ }Expand description
Exact-coverage gradient capture: one validated manifest drives both the declared contract and the recorded event population.
Implementations§
Source§impl GradientCapturePlan
impl GradientCapturePlan
Sourcepub fn from_named_vars(
root: impl Into<String>,
vars: impl IntoIterator<Item = (String, Var)>,
assign_family: impl Fn(&str) -> String,
families: Vec<GradientFamilyContract>,
) -> Result<Self>
pub fn from_named_vars( root: impl Into<String>, vars: impl IntoIterator<Item = (String, Var)>, assign_family: impl Fn(&str) -> String, families: Vec<GradientFamilyContract>, ) -> Result<Self>
Build a plan from named variables. Keys are sorted ascending and the exact gradient contract is validated (non-empty manifest, unique keys, family membership) with its SHA-256 digest bound at construction.
pub fn root(&self) -> &str
Sourcepub fn contract(&self) -> &GradientContract
pub fn contract(&self) -> &GradientContract
Validated exact gradient contract. Clone it into the capture contract’s
gradient_contract alongside CoverageLevel::Complete.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for GradientCapturePlan
impl !UnwindSafe for GradientCapturePlan
impl Freeze for GradientCapturePlan
impl Send for GradientCapturePlan
impl Sync for GradientCapturePlan
impl Unpin for GradientCapturePlan
impl UnsafeUnpin for GradientCapturePlan
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> ErasedDestructor for Twhere
T: 'static,
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