Class: Flounder::Expression::FunCall
- Defined in:
- lib/flounder/expression.rb
Instance Method Summary collapse
-
#initialize(domain, name, arguments) ⇒ FunCall
constructor
A new instance of FunCall.
- #to_sql ⇒ Object
Methods inherited from Expr
#&, #as, #cast, #db_quote, #eval, #to_immediate, #|
Constructor Details
#initialize(domain, name, arguments) ⇒ FunCall
Returns a new instance of FunCall.
79 80 81 82 83 84 |
# File 'lib/flounder/expression.rb', line 79 def initialize domain, name, arguments super(domain) @name = name @arguments = arguments end |
Instance Method Details
#to_sql ⇒ Object
86 87 88 89 |
# File 'lib/flounder/expression.rb', line 86 def to_sql @name.to_s << '(' << @arguments.map { |arg| eval(arg) }.join(', ') << ')' end |