Package ca.uhn.fhir.batch2.api
Interface IJobParametersValidator<T extends ca.uhn.fhir.model.api.IModelJson>
public interface IJobParametersValidator<T extends ca.uhn.fhir.model.api.IModelJson>
This interface can be used to validate the parameters
object supplied to start a job instance.
Batch2 automatically uses JSR 380 to validate the parameters object supplied to job start requests.
However not all validation is possible using that API. For example environment-specific rules, or rules about relationships between multiple parameters.
-
Method Summary
-
Method Details
-
validate
@Nullable List<String> validate(ca.uhn.fhir.rest.api.server.RequestDetails theRequestDetails, @Nonnull T theParameters) Validate the given job parameters.- Parameters:
theRequestDetails- The request details associated with the start requesttheParameters- The parameters object to validate- Returns:
- Any strings returned by this method are treated as validation failures and returned to the client initiating the job. Return
nullor an empty list to indicate that no validation failures occurred.
-