runValidationAsync
Runs a given validation within a form with schema formSchema and returns a future that completes with a list of its issues.
It is necessary to provide all information required to run the validation: the path of the value being validated, the value itself, the values of the dependencies (by dependency name), and the values of the external contexts that the validation depends on.
If the validation depends on values within the value being validated, then these may be omitted from the provided dependencyValues.
Otherwise, missing dependencies or external contexts will be passed to the validation as null, in which case the validation may or may not throw depending on its implementation.
Exceptions thrown while running the validation will not be caught by this function. As opposed to how a form manager operates, exceptions are not wrapped in a ValidationFailure nor emitted as part of the issues flow.
The future will complete exceptionally with InvalidPathException if path matches no schemas, with InvalidDependencyPathException if validation contains an invalid dependency, or with IllegalArgumentException when providing unknown names for dependencyValues or externalContexts or when providing mismatching dependency values for dependencies within value.
Runs a given validation within a form with a schema of type AnySchema and returns a future that completes with a list of its issues.
It is necessary to provide all information required to run the validation: the path of the value being validated, the value itself, the values of the dependencies (by dependency name), and the values of the external contexts that the validation depends on.
If the validation depends on values within the value being validated, then these may be omitted from the provided dependencyValues.
Otherwise, missing dependencies or external contexts will be passed to the validation as null, in which case the validation may or may not throw depending on its implementation.
Exceptions thrown while running the validation will not be caught by this function. As opposed to how a form manager operates, exceptions are not wrapped in a ValidationFailure nor emitted as part of the issues flow.
The future will complete exceptionally with InvalidPathException if path matches no schemas, with InvalidDependencyPathException if validation contains an invalid dependency, or with IllegalArgumentException when providing unknown names for dependencyValues or externalContexts or when providing mismatching dependency values for dependencies within value.