Class: Truemail::Auditor

Inherits:
Executor show all
Defined in:
lib/truemail/auditor.rb

Defined Under Namespace

Classes: Result

Instance Attribute Summary

Attributes inherited from Executor

#result

Instance Method Summary collapse

Constructor Details

#initialize(configuration:) ⇒ Auditor

Returns a new instance of Auditor.


11
12
13
# File 'lib/truemail/auditor.rb', line 11

def initialize(configuration:)
  @result = Truemail::Auditor::Result.new(configuration: configuration)
end

Instance Method Details

#as_jsonObject


20
21
22
# File 'lib/truemail/auditor.rb', line 20

def as_json
  Truemail::Log::Serializer::AuditorJson.call(self)
end

#runObject


15
16
17
18
# File 'lib/truemail/auditor.rb', line 15

def run
  Truemail::Audit::Ip.check(result)
  self
end