to_date()
public
Converts a Time object to a Date, dropping hour, minute, and second precision.
my_time = Time.now
my_time.to_date
your_time = Time.parse("1/13/2009 1:13:03 P.M.")
your_time.to_date
Show source
def to_date
::Date.new(year, month, day)
end