diff options
author | Francesco Rodriguez <lrodriguezsanc@gmail.com> | 2012-09-12 18:40:18 -0500 |
---|---|---|
committer | Francesco Rodriguez <lrodriguezsanc@gmail.com> | 2012-09-12 18:40:18 -0500 |
commit | 794a70f94485fb64ed1c49ba8532895306e2001c (patch) | |
tree | 44f096bdc08c2df55ce2278a87ea120ed2bee478 /activesupport/lib/active_support/core_ext/date_time/conversions.rb | |
parent | f4e180578c673194f58d4ff5a4a656cc51b2249e (diff) | |
download | rails-794a70f94485fb64ed1c49ba8532895306e2001c.tar.gz rails-794a70f94485fb64ed1c49ba8532895306e2001c.tar.bz2 rails-794a70f94485fb64ed1c49ba8532895306e2001c.zip |
update AS/core_ext docs [ci skip]
Diffstat (limited to 'activesupport/lib/active_support/core_ext/date_time/conversions.rb')
-rw-r--r-- | activesupport/lib/active_support/core_ext/date_time/conversions.rb | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/activesupport/lib/active_support/core_ext/date_time/conversions.rb b/activesupport/lib/active_support/core_ext/date_time/conversions.rb index 7c3a5eaace..b7d8414a9d 100644 --- a/activesupport/lib/active_support/core_ext/date_time/conversions.rb +++ b/activesupport/lib/active_support/core_ext/date_time/conversions.rb @@ -53,7 +53,8 @@ class DateTime alias_method :default_inspect, :inspect alias_method :inspect, :readable_inspect - # Returns DateTime with local offset for given year if format is local else offset is zero + # Returns DateTime with local offset for given year if format is local else + # offset is zero. # # DateTime.civil_from_format :local, 2012 # # => Sun, 01 Jan 2012 00:00:00 +0300 @@ -68,12 +69,12 @@ class DateTime civil(year, month, day, hour, min, sec, offset) end - # Converts self to a floating-point number of seconds since the Unix epoch. + # Converts +self+ to a floating-point number of seconds since the Unix epoch. def to_f seconds_since_unix_epoch.to_f end - # Converts self to an integer number of seconds since the Unix epoch. + # Converts +self+ to an integer number of seconds since the Unix epoch. def to_i seconds_since_unix_epoch.to_i end |