Class: Textus::Read::ValidateAll

Inherits:
Object
  • Object
show all
Defined in:
lib/textus/read/validate_all.rb

Instance Method Summary collapse

Constructor Details

#initialize(container:, call:) ⇒ ValidateAll

Returns a new instance of ValidateAll.



4
5
6
7
8
9
10
# File 'lib/textus/read/validate_all.rb', line 4

def initialize(container:, call:)
  @container = container
  @call      = call
  @manifest  = container.manifest
  @schemas   = container.schemas
  @audit_log = container.audit_log
end

Instance Method Details

#callObject



12
13
14
15
16
17
18
19
# File 'lib/textus/read/validate_all.rb', line 12

def call
  Validator.new(
    reader: Get.new(container: @container, call: @call),
    manifest: @manifest,
    audit_log: @audit_log,
    schema_for: ->(name) { @schemas.fetch_or_nil(name) },
  ).call
end