Class: BabySMS::Report

Inherits:
Object
  • Object
show all
Defined in:
lib/babysms/report.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(adapter) ⇒ Report

Returns a new instance of Report.



6
7
8
9
# File 'lib/babysms/report.rb', line 6

def initialize(adapter)
  @adapter = adapter
  @log = []
end

Instance Attribute Details

#adapterObject (readonly)

Returns the value of attribute adapter.



3
4
5
# File 'lib/babysms/report.rb', line 3

def adapter
  @adapter
end

#logObject (readonly)

Returns the value of attribute log.



4
5
6
# File 'lib/babysms/report.rb', line 4

def log
  @log
end

Instance Method Details

#incoming_message(message) ⇒ Object



11
12
13
# File 'lib/babysms/report.rb', line 11

def incoming_message(message)
  log.push([adapter, :incoming_message, { message: message }])
end