Class: OnStomp::Failover::Buffers::Base
- Inherits:
-
Object
- Object
- OnStomp::Failover::Buffers::Base
- Defined in:
- lib/onstomp/failover/buffers/base.rb
Overview
Instance Method Summary (collapse)
-
- (Fixnum) buffered
Returns the number of frames currently sitting in the buffer.
-
- (Base) initialize(failover)
constructor
A new instance of Base.
Constructor Details
- (Base) initialize(failover)
A new instance of Base
7 8 9 10 11 12 |
# File 'lib/onstomp/failover/buffers/base.rb', line 7 def initialize failover @failover = failover @buffer_mutex = Mutex.new @buffer = [] @txs = {} end |
Instance Method Details
- (Fixnum) buffered
Returns the number of frames currently sitting in the buffer.
16 17 18 |
# File 'lib/onstomp/failover/buffers/base.rb', line 16 def buffered @buffer.length end |