Class: Textus::Read::Doctor

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

Overview

Dispatched use case for the ‘doctor` verb. The health-check report is built by the Textus::Doctor library module; this class is the uniform (container:, call:) entry point that Dispatcher::VERBS resolves to. The acting role is irrelevant to a read-only health check, so `call` is not consulted.

Instance Method Summary collapse

Constructor Details

#initialize(container:, call:) ⇒ Doctor

Returns a new instance of Doctor.



9
10
11
12
# File 'lib/textus/read/doctor.rb', line 9

def initialize(container:, call:)
  @container = container
  @call      = call
end

Instance Method Details

#call(checks: nil) ⇒ Object



14
15
16
# File 'lib/textus/read/doctor.rb', line 14

def call(checks: nil)
  Textus::Doctor.build(container: @container, checks: checks)
end