Method TryGetLastRun
- Namespace
- Oscova.Agents.Tasks
- Assembly
- Oscova.Agents.dll
TryGetLastRun(string, string, out AgentTaskRun?)
Returns the most recent run for a task, whether currently running or completed, as long as it has not been replaced by a newer run. Returns false if no run has started since the last app restart.
public bool TryGetLastRun(string userId, string taskId, out AgentTaskRun? run)Parameters
userIdstring-
The task owner's user identifier.
taskIdstring-
The task identifier to check.
runAgentTaskRun?-
The latest owner-bound run when found.