Class: Spider::QueryFuncs::SelectFunction
- Defined in:
- lib/spiderfw/model/query_funcs.rb
Instance Attribute Summary collapse
-
#as ⇒ Object
readonly
Returns the value of attribute as.
-
#function ⇒ Object
readonly
Returns the value of attribute function.
Instance Method Summary collapse
-
#initialize(function, as) ⇒ SelectFunction
constructor
A new instance of SelectFunction.
- #inspect ⇒ Object
- #method_missing(method, *args) ⇒ Object
Constructor Details
#initialize(function, as) ⇒ SelectFunction
Returns a new instance of SelectFunction.
107 108 109 110 |
# File 'lib/spiderfw/model/query_funcs.rb', line 107 def initialize(function, as) @function = function @as = as end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args) ⇒ Object
116 117 118 |
# File 'lib/spiderfw/model/query_funcs.rb', line 116 def method_missing(method, *args) @function.send(method, *args) end |
Instance Attribute Details
#as ⇒ Object (readonly)
Returns the value of attribute as.
104 105 106 |
# File 'lib/spiderfw/model/query_funcs.rb', line 104 def as @as end |
#function ⇒ Object (readonly)
Returns the value of attribute function.
104 105 106 |
# File 'lib/spiderfw/model/query_funcs.rb', line 104 def function @function end |
Instance Method Details
#inspect ⇒ Object
112 113 114 |
# File 'lib/spiderfw/model/query_funcs.rb', line 112 def inspect "#{@function.inspect} AS #{@as}" end |