class Concurrent::Channel::Buffer::Dropping

A non-blocking, buffered buffer of fixed maximum capacity. When the maximum capacity is reached subsequent {#put} and {#offer} operations will complete but the `put` item will be discarded; no transfer will occur.

Public Instance Methods

blocking?() click to toggle source

@!macro channel_buffer_blocking_question

Always returns `false`.

# File lib/concurrent/channel/buffer/dropping.rb, line 35
def blocking?
  false
end

Private Instance Methods

ns_full?() click to toggle source

@!macro channel_buffer_full_question

# File lib/concurrent/channel/buffer/dropping.rb, line 42
def ns_full?
  false
end
ns_put_onto_buffer(item) click to toggle source

@!macro channel_buffer_put

# File lib/concurrent/channel/buffer/dropping.rb, line 47
def ns_put_onto_buffer(item)
  buffer.push(item) unless buffer.size == capacity
end