pub struct NewEffect {
pub id: EffectId,
pub key: EffectKey,
pub kind: EffectKind,
pub input: Option<Value>,
pub input_fingerprint: Option<String>,
pub created_by: Option<String>,
pub now: SystemTime,
}Expand description
A new effect to record.
Fields§
§id: EffectIdThe id the record gets if it is inserted.
key: EffectKeyThe logical identity; unique per store.
kind: EffectKindThe effect’s kind.
input: Option<Value>The input, already redacted for storage.
input_fingerprint: Option<String>A stable hash of the unredacted input, used to reject a reused key with a different input.
created_by: Option<String>Who asked for the effect, e.g. agent:refund-agent.
now: SystemTimeThe creation time.
Implementations§
Source§impl NewEffect
impl NewEffect
Sourcepub fn new(key: EffectKey, kind: EffectKind, now: SystemTime) -> Self
pub fn new(key: EffectKey, kind: EffectKind, now: SystemTime) -> Self
A new effect with a fresh id and no input or actor.
Trait Implementations§
impl StructuralPartialEq for NewEffect
Auto Trait Implementations§
impl Freeze for NewEffect
impl RefUnwindSafe for NewEffect
impl Send for NewEffect
impl Sync for NewEffect
impl Unpin for NewEffect
impl UnsafeUnpin for NewEffect
impl UnwindSafe for NewEffect
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