Class: Sequel::SQL::Function

Class | Sequel::SQL::Function
In: | lib/sequel_core/sql.rb
Parent: | GenericExpression

Represents an SQL function call.

### Methods

== new to_s

### Attributes

args | [R] | The array of arguments to pass to the function (may be blank)
f | [R] | The SQL function to call

### Public Class methods

new(f, *args)

Set the attributes to the given arguments

[Source]

         # File lib/sequel_core/sql.rb, line 551
    551:       def initialize(f, *args)
    552:         @f, @args = f, args
    553:       end

### Public Instance methods

==(x)

Functions are considered equivalent if they have the same class, function, and arguments.

[Source]

         # File lib/sequel_core/sql.rb, line 557
    557:       def ==(x)
    558:          x.class == self.class && @f == x.f && @args == x.args
    559:       end

to_s(ds)

Delegate the creation of the resulting SQL to the given dataset, since it may be database dependent.

[Source]

         # File lib/sequel_core/sql.rb, line 563
    563:       def to_s(ds)
    564:         ds.function_sql(self)
    565:       end

[Validate]