Module: Inferno::DSL::FHIRResourceValidation::ClassMethods
- Defined in:
- lib/inferno/dsl/fhir_resource_validation.rb
Instance Method Summary collapse
-
#fhir_resource_validator(name = :default, required_suite_options: nil, &block) ⇒ Object
Define a validator.
Instance Method Details
#fhir_resource_validator(name = :default, required_suite_options: nil, &block) ⇒ Object
Define a validator
383 384 385 386 387 388 389 390 391 392 |
# File 'lib/inferno/dsl/fhir_resource_validation.rb', line 383 def fhir_resource_validator(name = :default, required_suite_options: nil, &block) current_validators = fhir_validators[name] || [] new_validator = Inferno::DSL::FHIRResourceValidation::Validator.new(name, id, , &block) current_validators.reject! { |validator| validator.requirements == } current_validators << new_validator fhir_validators[name] = current_validators end |