Class: Arel::Collectors::Bind
- Inherits:
-
Object
- Object
- Arel::Collectors::Bind
- Defined in:
- lib/arel/collectors/bind.rb
Instance Attribute Summary collapse
-
#retryable ⇒ Object
Returns the value of attribute retryable.
Instance Method Summary collapse
- #<<(str) ⇒ Object
- #add_bind(bind) ⇒ Object
- #add_binds(binds, proc_for_binds = nil) ⇒ Object
-
#initialize ⇒ Bind
constructor
A new instance of Bind.
- #value ⇒ Object
Constructor Details
#initialize ⇒ Bind
Returns a new instance of Bind.
8 9 10 |
# File 'lib/arel/collectors/bind.rb', line 8 def initialize @binds = [] end |
Instance Attribute Details
#retryable ⇒ Object
Returns the value of attribute retryable.
6 7 8 |
# File 'lib/arel/collectors/bind.rb', line 6 def retryable @retryable end |
Instance Method Details
#<<(str) ⇒ Object
12 13 14 |
# File 'lib/arel/collectors/bind.rb', line 12 def <<(str) self end |
#add_bind(bind) ⇒ Object
16 17 18 19 |
# File 'lib/arel/collectors/bind.rb', line 16 def add_bind(bind, &) @binds << bind self end |
#add_binds(binds, proc_for_binds = nil) ⇒ Object
21 22 23 24 |
# File 'lib/arel/collectors/bind.rb', line 21 def add_binds(binds, proc_for_binds = nil) @binds.concat proc_for_binds ? binds.map(&proc_for_binds) : binds self end |
#value ⇒ Object
26 27 28 |
# File 'lib/arel/collectors/bind.rb', line 26 def value @binds end |