< Summary

Information
Class: Elsa.Api.Client.Resources.WorkflowDefinitions.Models.WorkflowDefinition
Assembly: Elsa.Api.Client
File(s): /home/runner/work/elsa-core/elsa-core/src/clients/Elsa.Api.Client/Resources/WorkflowDefinitions/Models/WorkflowDefinition.cs
Line coverage
73%
Covered lines: 11
Uncovered lines: 4
Coverable lines: 15
Total lines: 85
Line coverage: 73.3%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
get_DefinitionId()100%11100%
get_Name()100%11100%
get_Description()100%210%
get_ToolVersion()100%11100%
get_Options()100%11100%
get_Variables()100%11100%
get_Inputs()100%11100%
get_Outputs()100%11100%
get_Outcomes()100%11100%
get_CustomProperties()100%11100%
get_ProviderName()100%210%
get_MaterializerName()100%210%
get_MaterializerContext()100%210%
get_Root()100%11100%
get_IsReadonly()100%11100%

File(s)

/home/runner/work/elsa-core/elsa-core/src/clients/Elsa.Api.Client/Resources/WorkflowDefinitions/Models/WorkflowDefinition.cs

#LineLine coverage
 1using System.Text.Json.Nodes;
 2using Elsa.Api.Client.Shared.Models;
 3
 4namespace Elsa.Api.Client.Resources.WorkflowDefinitions.Models;
 5
 6/// <summary>
 7/// Represents a linked workflow definition.
 8/// </summary>
 9public class WorkflowDefinition : LinkedEntity
 10{
 11    /// <summary>
 12    /// The logical ID of the workflow. This ID is the same across versions.
 13    /// </summary>
 114    public string DefinitionId { get; set; } = null!;
 15
 16    /// <summary>
 17    /// The name of the workflow.
 18    /// </summary>
 119    public string? Name { get; set; }
 20
 21    /// <summary>
 22    /// A short description of that the workflow is about.
 23    /// </summary>
 024    public string? Description { get; set; }
 25
 26    /// <summary>
 27    /// The version of the tool that created this workflow.
 28    /// </summary>
 129    public Version? ToolVersion { get; set; }
 30
 31    /// <summary>
 32    /// A set of options for the workflow.
 33    /// </summary>
 234    public WorkflowOptions Options { get; set; } = new();
 35
 36    /// <summary>
 37    /// A set of workflow variables that are accessible throughout the workflow.
 38    /// </summary>
 239    public ICollection<Variable> Variables { get; set; } = new List<Variable>();
 40
 41    /// <summary>
 42    /// A set of input definitions.
 43    /// </summary>
 244    public ICollection<InputDefinition> Inputs { get; set; } = new List<InputDefinition>();
 45
 46    /// <summary>
 47    /// A set of output definitions.
 48    /// </summary>
 249    public ICollection<OutputDefinition> Outputs { get; set; } = new List<OutputDefinition>();
 50
 51    /// <summary>
 52    /// A set of possible outcomes for this workflow.
 53    /// </summary>
 254    public ICollection<string> Outcomes { get; set; } = new List<string>();
 55
 56    /// <summary>
 57    /// Stores custom information about the workflow. Can be used to store application-specific properties to associate 
 58    /// </summary>
 259    public IDictionary<string, object> CustomProperties { get; set; } = new Dictionary<string, object>();
 60
 61    /// <summary>
 62    /// The name of the workflow provider that created this workflow, if any.
 63    /// </summary>
 064    public string? ProviderName { get; set; }
 65
 66    /// <summary>
 67    /// The name of the workflow materializer to interpret the <c>StringData</c> or <c>BinaryData</c>.
 68    /// </summary>
 069    public string MaterializerName { get; set; } = null!;
 70
 71    /// <summary>
 72    /// Provider-specific data.
 73    /// </summary>
 074    public string? MaterializerContext { get; set; }
 75
 76    /// <summary>
 77    /// The root activity of the workflow.
 78    /// </summary>
 279    public JsonObject Root { get; set; } = null!;
 80
 81    /// <summary>
 82    /// An option to use the workflow as a readonly workflow.
 83    /// </summary>
 184    public bool IsReadonly { get; set; }
 85}