pub struct TriggerDefinitionDTO {
pub trigger_id: TriggerDefinitionId,
pub task_id: TaskId,
pub condition_ids: Vec<ConditionId>,
pub logic: TriggerLogic,
pub argument_template: Option<Value>,
}Expand description
A trigger definition links conditions to a target task.
When the conditions are satisfied (according to logic), the target
task is invoked with the given argument_template.
Fields§
§trigger_id: TriggerDefinitionId§task_id: TaskId§condition_ids: Vec<ConditionId>§logic: TriggerLogic§argument_template: Option<Value>Optional static arguments to pass to the triggered task.
Implementations§
Source§impl TriggerDefinitionDTO
impl TriggerDefinitionDTO
Sourcepub fn compute_trigger_id(
task_id: &TaskId,
condition_ids: &[ConditionId],
logic: TriggerLogic,
) -> TriggerDefinitionId
pub fn compute_trigger_id( task_id: &TaskId, condition_ids: &[ConditionId], logic: TriggerLogic, ) -> TriggerDefinitionId
Compute a deterministic trigger ID from (task_id + sorted conditions + logic).
Trait Implementations§
Source§impl Clone for TriggerDefinitionDTO
impl Clone for TriggerDefinitionDTO
Source§fn clone(&self) -> TriggerDefinitionDTO
fn clone(&self) -> TriggerDefinitionDTO
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TriggerDefinitionDTO
impl Debug for TriggerDefinitionDTO
Source§impl<'de> Deserialize<'de> for TriggerDefinitionDTO
impl<'de> Deserialize<'de> for TriggerDefinitionDTO
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<TriggerDefinitionDTO, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<TriggerDefinitionDTO, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for TriggerDefinitionDTO
impl Serialize for TriggerDefinitionDTO
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for TriggerDefinitionDTO
impl RefUnwindSafe for TriggerDefinitionDTO
impl Send for TriggerDefinitionDTO
impl Sync for TriggerDefinitionDTO
impl Unpin for TriggerDefinitionDTO
impl UnsafeUnpin for TriggerDefinitionDTO
impl UnwindSafe for TriggerDefinitionDTO
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