class Runt::TemporalDate

TExpr that provides for inclusion of an arbitrary date.

Attributes

date_expr[R]

Public Class Methods

new(date_expr) click to toggle source
# File lib/runt/temporalexpression.rb, line 216
def initialize(date_expr)
  @date_expr = date_expr
end

Public Instance Methods

==(o) click to toggle source
Calls superclass method
# File lib/runt/temporalexpression.rb, line 220
def ==(o)
  o.is_a?(TemporalDate) ? date_expr == o.date_expr : super(o)
end
include?(date_expr) click to toggle source

Will return true if the supplied object is == to that which was used to create this instance

# File lib/runt/temporalexpression.rb, line 226
def include?(date_expr)
  return date_expr.include?(@date_expr) if date_expr.respond_to?(:include?)
  return true if @date_expr == date_expr
  false
end
to_s() click to toggle source
# File lib/runt/temporalexpression.rb, line 232
def to_s
  @date_expr.to_s
end