Method CheckAsync
- Namespace
- IntentSharp.Targets
- Assembly
- IntentSharp.dll
CheckAsync(CommandPlan, CancellationToken)
Checks plan as it would be checked before it runs, with data.stage plan: the
target inspects it and the rule sets judge it. No model is called and nothing is executed.
public ValueTask<CommandCheck> CheckAsync(CommandPlan plan, CancellationToken cancellationToken = default)
Parameters
planCommandPlanThe plan, from PlanAsync(string, object?, CancellationToken) or built by the caller.
cancellationTokenCancellationTokenCancels the call.
Returns
- ValueTask<CommandCheck>
The verdict. A plan with no command is refused: nothing was checked.
Exceptions
- ArgumentNullException
planis null.- TargetOperationException
Describing the target or inspecting the command failed.