pub struct Config {
pub name: String,
pub title: String,
pub description: String,
pub role: Role,
pub aliases: Vec<String>,
pub eligibility: Eligibility,
pub dependencies: Option<Dependencies>,
}Expand description
The configuration for an Activity, defining its metadata, eligibility criteria, and execution semantics.
Fields§
§name: StringA unique identifier for the activity.
title: StringA human-readable title for the activity.
description: StringA brief description of the activity’s purpose and functionality.
role: RoleThe role of the activity within the workflow, determining its behavior and interaction with other activities.
aliases: Vec<String>Names by which this activity has previously been known.
eligibility: EligibilityThe conditions that determine when the activity should execute.
dependencies: Option<Dependencies>Implementations§
Source§impl Config
impl Config
Sourcepub fn action(
name: impl Into<String>,
title: impl Into<String>,
description: impl Into<String>,
) -> Self
pub fn action( name: impl Into<String>, title: impl Into<String>, description: impl Into<String>, ) -> Self
Creates a new instance with role Role::Action and the specified name, title, and description.
Sourcepub fn aliases<I, S>(self, aliases: I) -> Self
pub fn aliases<I, S>(self, aliases: I) -> Self
Sets the aliases field, which contains names by which this activity has previously been known.
Sourcepub fn eligibility(self, eligibility: Eligibility) -> Self
pub fn eligibility(self, eligibility: Eligibility) -> Self
Sets the eligibility field, which defines the conditions under which this activity is eligible for execution.
Sourcepub fn downstream_dependencies<I, S>(self, dependencies: I) -> Self
pub fn downstream_dependencies<I, S>(self, dependencies: I) -> Self
Sets the dependencies field to specify dependencies that should be triggered after this activity completes.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Config
impl<'de> Deserialize<'de> for Config
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for Config
impl RefUnwindSafe for Config
impl Send for Config
impl Sync for Config
impl Unpin for Config
impl UnwindSafe for Config
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> 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