Skip to main content

SignalDefinition

Trait SignalDefinition 

Source
pub trait SignalDefinition {
    type Workflow: WorkflowDefinition;
    type Input: TemporalDeserializable + TemporalSerializable + 'static;

    // Required method
    fn name(&self) -> &str;
}
Expand description

Implement on a marker struct to define a signal.

Typically, you will want to use the #[signal] attribute inside a #[workflow_methods] macro to define signals. However, this trait may be implemented manually if desired.

Required Associated Types§

Source

type Workflow: WorkflowDefinition

The workflow type this signal belongs to

Source

type Input: TemporalDeserializable + TemporalSerializable + 'static

Type of the input argument to the signal.

Required Methods§

Source

fn name(&self) -> &str

The workflow type name.

Implementors§