Class: Memplify::Reporter

Inherits:
Object
  • Object
show all
Defined in:
lib/memplify/reporter.rb

Instance Method Summary collapse

Constructor Details

#initialize(identifier, result) ⇒ Reporter

Returns a new instance of Reporter.



5
6
7
8
# File 'lib/memplify/reporter.rb', line 5

def initialize(identifier, result)
  @identifier = identifier
  @result = result
end

Instance Method Details

#callObject



10
11
12
13
14
# File 'lib/memplify/reporter.rb', line 10

def call
  @result.pretty_print(string_io, **options)

  Net::HTTP.post(uri, body.to_json, headers)
end