Class: Arel::Collectors::Bind

Inherits:
Object
  • Object
show all
Defined in:
lib/arel/collectors/bind.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeBind

Returns a new instance of Bind.



8
9
10
# File 'lib/arel/collectors/bind.rb', line 8

def initialize
  @binds = []
end

Instance Attribute Details

#retryableObject

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

#valueObject



26
27
28
# File 'lib/arel/collectors/bind.rb', line 26

def value
  @binds
end