Sha256: 9b9f4b66731be02041606c034ed1557bb49061220a71702f1ea27615c62f5884

Contents?: true

Size: 871 Bytes

Versions: 1

Compression:

Stored size: 871 Bytes

Contents

module ByStar

  module Directional

    def before(*args)
      with_by_star_options(*args) do |time, options|
        field = by_star_start_field(options)
        time = ByStar::Normalization.time(time)
        by_star_before_query(self, field, time)
      end
    end
    alias_method :before_now, :before

    def after(*args)
      with_by_star_options(*args) do |time, options|
        field = by_star_start_field(options)
        time = ByStar::Normalization.time(time)
        by_star_after_query(self, field, time)
      end
    end
    alias_method :after_now, :after

    def oldest(*args)
      with_by_star_options(*args) do |time, options|
        oldest_query(options)
      end
    end

    def newest(*args)
      with_by_star_options(*args) do |time, options|
        newest_query(options)
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
by_star-4.0.1 lib/by_star/directional.rb