Class: Twobook::AccountQuery::OrQuery
- Inherits:
-
Twobook::AccountQuery
- Object
- Twobook::AccountQuery
- Twobook::AccountQuery::OrQuery
- Defined in:
- lib/twobook/account_query.rb
Instance Attribute Summary collapse
-
#first ⇒ Object
readonly
Returns the value of attribute first.
-
#second ⇒ Object
readonly
Returns the value of attribute second.
Instance Method Summary collapse
-
#initialize(first, second) ⇒ OrQuery
constructor
A new instance of OrQuery.
- #none? ⇒ Boolean
- #on(array) ⇒ Object
Methods inherited from Twobook::AccountQuery
#after, #and, named, #named, none, #none, #or, where, #where
Constructor Details
#initialize(first, second) ⇒ OrQuery
Returns a new instance of OrQuery.
194 195 196 197 |
# File 'lib/twobook/account_query.rb', line 194 def initialize(first, second) @first = first @second = second end |
Instance Attribute Details
#first ⇒ Object (readonly)
Returns the value of attribute first.
192 193 194 |
# File 'lib/twobook/account_query.rb', line 192 def first @first end |
#second ⇒ Object (readonly)
Returns the value of attribute second.
192 193 194 |
# File 'lib/twobook/account_query.rb', line 192 def second @second end |
Instance Method Details
#none? ⇒ Boolean
199 200 201 |
# File 'lib/twobook/account_query.rb', line 199 def none? @first.none? && @second.none? end |
#on(array) ⇒ Object
203 204 205 |
# File 'lib/twobook/account_query.rb', line 203 def on(array) @first.on(array) | @second.on(array) end |