Class: Arel::Nodes::Ascending

Inherits:
Ordering
  • Object
show all
Defined in:
activerecord/lib/arel/nodes/ascending.rb

Instance Method Summary collapse

Instance Method Details

#ascending?Boolean

Returns:

  • (Boolean)


14
15
16
# File 'activerecord/lib/arel/nodes/ascending.rb', line 14

def ascending?
  true
end

#descending?Boolean

Returns:

  • (Boolean)


18
19
20
# File 'activerecord/lib/arel/nodes/ascending.rb', line 18

def descending?
  false
end

#directionObject



10
11
12
# File 'activerecord/lib/arel/nodes/ascending.rb', line 10

def direction
  :asc
end

#reverseObject



6
7
8
# File 'activerecord/lib/arel/nodes/ascending.rb', line 6

def reverse
  Descending.new(expr)
end