Methods

Class Index [+]

Quicksearch

DataMapper::Query::Direction

Public Class Methods

new(target, operator = :asc) click to toggle source

@api private

    # File lib/dm-core/query/direction.rb, line 31
31:       def initialize(target, operator = :asc)
32:         super
33:       end

Public Instance Methods

get(resource) click to toggle source

@api private

    # File lib/dm-core/query/direction.rb, line 24
24:       def get(resource)
25:         Sort.new(target.get(resource), @operator == :asc)
26:       end
reverse!() click to toggle source

@api private

    # File lib/dm-core/query/direction.rb, line 18
18:       def reverse!
19:         @operator = @operator == :asc ? :desc : :asc
20:         self
21:       end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.