Class: Async::RSpec::Memory::Allocation
- Inherits:
-
Struct
- Object
- Struct
- Async::RSpec::Memory::Allocation
- Defined in:
- lib/async/rspec/memory.rb
Instance Attribute Summary collapse
-
#count ⇒ Object
Returns the value of attribute count.
-
#size ⇒ Object
Returns the value of attribute size.
Instance Method Summary collapse
Instance Attribute Details
#count ⇒ Object
Returns the value of attribute count
27 28 29 |
# File 'lib/async/rspec/memory.rb', line 27 def count @count end |
#size ⇒ Object
Returns the value of attribute size
27 28 29 |
# File 'lib/async/rspec/memory.rb', line 27 def size @size end |
Instance Method Details
#<<(object) ⇒ Object
28 29 30 31 |
# File 'lib/async/rspec/memory.rb', line 28 def << object self.count += 1 self.size += ObjectSpace.memsize_of(object) end |