Class: DohLogger::MemoryAcceptor
- Defined in:
- lib/doh/logger/memory_acceptor.rb
Instance Attribute Summary collapse
-
#events ⇒ Object
Returns the value of attribute events.
Instance Method Summary collapse
-
#initialize ⇒ MemoryAcceptor
constructor
A new instance of MemoryAcceptor.
- #log(event) ⇒ Object
Constructor Details
#initialize ⇒ MemoryAcceptor
Returns a new instance of MemoryAcceptor.
6 7 8 |
# File 'lib/doh/logger/memory_acceptor.rb', line 6 def initialize @events = [] end |
Instance Attribute Details
#events ⇒ Object
Returns the value of attribute events.
4 5 6 |
# File 'lib/doh/logger/memory_acceptor.rb', line 4 def events @events end |
Instance Method Details
#log(event) ⇒ Object
10 11 12 |
# File 'lib/doh/logger/memory_acceptor.rb', line 10 def log(event) @events.push(event) end |