Class: Arel::Nodes::NamedFunction

Inherits:
Function
  • Object
show all
Includes:
Predications
Defined in:
lib/ransack/adapters/active_record/3.0/compat.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Predications

#as

Constructor Details

#initialize(name, expr, aliaz = nil) ⇒ NamedFunction

Returns a new instance of NamedFunction.



67
68
69
70
71
# File 'lib/ransack/adapters/active_record/3.0/compat.rb', line 67

def initialize name, expr, aliaz = nil
  super(expr, aliaz)
  @name = name
  @distinct = false
end

Instance Attribute Details

#distinctObject

Returns the value of attribute distinct.



63
64
65
# File 'lib/ransack/adapters/active_record/3.0/compat.rb', line 63

def distinct
  @distinct
end

#nameObject

Returns the value of attribute name.



63
64
65
# File 'lib/ransack/adapters/active_record/3.0/compat.rb', line 63

def name
  @name
end