Class: Rage::Ext::ActiveRecord::ConnectionPool::BlackHoleList
- Inherits:
-
Object
- Object
- Rage::Ext::ActiveRecord::ConnectionPool::BlackHoleList
- Defined in:
- lib/rage/ext/active_record/connection_pool.rb
Overview
items can be added but not removed
Instance Method Summary collapse
- #<<(el) ⇒ Object
-
#initialize(arr) ⇒ BlackHoleList
constructor
A new instance of BlackHoleList.
- #length ⇒ Object
- #shift ⇒ Object
- #to_a ⇒ Object
Constructor Details
#initialize(arr) ⇒ BlackHoleList
Returns a new instance of BlackHoleList.
6 7 8 |
# File 'lib/rage/ext/active_record/connection_pool.rb', line 6 def initialize(arr) @arr = arr end |
Instance Method Details
#<<(el) ⇒ Object
10 11 12 |
# File 'lib/rage/ext/active_record/connection_pool.rb', line 10 def <<(el) @arr << el end |
#length ⇒ Object
18 19 20 |
# File 'lib/rage/ext/active_record/connection_pool.rb', line 18 def length 0 end |
#shift ⇒ Object
14 15 16 |
# File 'lib/rage/ext/active_record/connection_pool.rb', line 14 def shift nil end |
#to_a ⇒ Object
22 23 24 |
# File 'lib/rage/ext/active_record/connection_pool.rb', line 22 def to_a @arr end |