Class WorkflowProcessScheme
OptimaJet.Workflow.SQLite.WorkflowProcessScheme
Database object for workflow process scheme operations.
Namespace: OptimaJet.Workflow.SQLite
public class WorkflowProcessScheme : DbObject<ProcessSchemeEntity>Inheritance
- Object
- DbObject<ProcessSchemeEntity>
Constructors
public WorkflowProcessScheme(string schemaName, int commandTimeout) #Initializes a new instance of WorkflowProcessScheme.
Parameters
Name
Type
Description
schemaNameStringThe database schema name.
commandTimeoutInt32The command timeout in seconds.
Methods
public Task<ProcessSchemeEntity[]> SelectAsync(SqliteConnection connection, string schemeCode, string tenantId, bool? isObsolete, Guid? rootSchemeId) #Selects process scheme entities by scheme code with optional filters for tenant, obsolete status, and root scheme.
Parameters
Name
Type
Description
connectionSqliteConnectionThe SQLite connection.
schemeCodeStringThe scheme code to search for.
tenantIdStringThe tenant identifier, or
null for shared schemes.isObsoleteNullable<Boolean>Filter by obsolete status, or
null to include all.rootSchemeIdNullable<Guid>The root scheme identifier, or
null for schemes without a root.Returns
Type
Description
Task<ProcessSchemeEntity[]>An array of matching process scheme entities.
public Task<int> SetObsoleteAsync(SqliteConnection connection, string schemeCode, string tenantId) #Marks all schemes matching the specified scheme code (and optionally tenant) as obsolete.
Parameters
Name
Type
Description
connectionSqliteConnectionThe SQLite connection.
schemeCodeStringThe scheme code to mark as obsolete.
tenantIdStringThe tenant identifier, or
null for shared schemes.Returns
Type
Description
Task<Int32>The number of rows affected.
public Task DeleteUnusedAsync(SqliteConnection connection) #Deletes obsolete process schemes that are not referenced by any process instance. Rolls back and throws if orphaned scheme records are detected.
Parameters
Name
Type
Description
connectionSqliteConnectionThe SQLite connection.
Returns
Type
Description
TaskA task that represents the asynchronous operation.