Class TimeSpan

成瀬です。

[ruby-list:44398] で DateTime ã«å¯¾ã™ã‚‹åŠ ç®—ãŒè©±é¡Œã«ãªã£ã¦ã„ã¾ã™ãŒã€ç¾åœ¨ã®
æ–¹æ³•ã¯ä»¥ä¸‹ã®ã‚ˆã†ãªæ¬ ç‚¹ãŒã‚ã‚‹ã¨æ€ã„ã¾ã™ã€‚

  • Rational を使う方法は直観的でない
  • 24*60 ç­‰ãƒžã‚¸ãƒƒã‚¯ãƒŠãƒ³ãƒãƒ¼ã‚’é »ç¹ã«ç”¨ã„ã‚‹å¿…è¦ãŒã‚ã‚‹
  • Time は秒、Date/DateTimeは日を基本単位としているため、
     値を流用するとはまる

puts Time.now + 3600
2007-12-27 19:19:44 +0900 #1時間後
puts DateTime.now + 3600
2017-11-04T18:11:58+09:00 #10年後!

TimeSpan ã®ã‚ˆã†ãªã‚¯ãƒ©ã‚¹ã‚’è¿½åŠ ã™ã‚‹ã¨ä»¥ä¸‹ã®ã‚ˆã†ã«ãªã£ã¦èª¤è§£ãŒå°‘ãªããªã‚‹ã®
ですが、いかがでしょうか。

puts Time.now + TimeSpan(:days => 1)
2007-12-28 17:57:40 +0900
puts Time.now + TimeSpan(:hours => 1)
2007-12-27 18:57:40 +0900
puts DateTime.now + TimeSpan(:days => 1)
2007-12-28T17:57:40+09:00
puts DateTime.now + TimeSpan(:hours => 1)
2007-12-27T18:57:40+09:00

On Thu, 27 Dec 2007 18:33:00 +0900
In article [email protected]
[[ruby-dev:32823] class TimeSpan]
“NARUSE, Yui” [email protected] wrote:

  • Time e$B$OIC!"e(BDate/DateTimee$B$OF|$r4pK\C10L$H$7$F$$$k$?$a!"e(B
    e$B!!CM$rN.MQ$9$k$H$O$^$ke(B

e$B$"!"$=$l:G6a$d$j$^$7$?!#e([email protected]$H;W$C$Fe(B 1.week
e$BB-$7$?$i$;$s$M$s$4!De(B

TimeSpan e$B$N$h$&$J%/%i%9$rDI2C$9$k$H0J2<$N$h$&$K$J$C$F8m2r$,>/$J$/$J$k$Ne(B
e$B$G$9$,!"$$$+$,$G$7$g$&$+!#e(B

:month(s), :year(s) e$B$,M_$7$/$J$j$^$9$M$(!#e(B

Time.local(2007,12,1) + TimeSpam(:months => 1) # => 2008-01-01
Time.local(2004,2,29) + TimeSpam(:years => 1) # => 2005-02-28

e$B$"$H$Oe(B :week(s)

Date e$B$Oe(B << >> e$B$G%5%]!<%H$7$F$^$9$M!#e(B
Date.today >> 1 # => 2008-01-27

PostgreSQL e$B$Ne(B INTERVAL e$B7?$,e(B ‘1 month’
e$B$H$+%5%]!<%H$7$F$$$k$N$G!"e(B
e$B$J$*$5$i!#e(B

[ruby-list:44398] e$B$Ge(B DateTime e$B$KBP$9$k2C;;$,OCBj$K$J$C$F$$$^$9$,!“8=:_$Ne(B
e$BJ}K!$O0J2<$N$h$&[email protected]$,$”$k$H;W$$$^$9!#e(B
(e$BCfN,e(B)
TimeSpan e$B$N$h$&$J%/%i%9$rDI2C$9$k$H0J2<$N$h$&$K$J$C$F8m2r$,>/$J$/$J$k$Ne(B
e$B$G$9$,!"$$$+$,$G$7$g$&$+!#e(B

date4 e$B$G$O!“e(BDelta e$B%/%i%9$,$”$C$F!"$3$s$J$3$H$b$G$-$^$9!#e(B

require ‘date4’

Date4::Delta.new(:days=>6) + Date4::Delta.new(:hours=>4) * 6
#=> #<Date4::Delta: 7>

dt = DateTime4.new(2006,6,6)
dt -= Date4::Delta.parse(‘180 days and 12 hours’)
puts dt.strftime(’%+’) # Wed Dec 7 12:00:00 +00:00 2005

require ‘date4/timezone/posix’

EST = Date4::TimeZone::POSIX.new(‘EST5EDT,M4.1.0,M10.5.0’)
dt = DateTime4.new(2006,6,6,:tz=>EST)
dt += Date4::Delta.parse(’-(2 fortnights - 1 hour * 673)’)
puts dt.strftime(’%+’) # Tue Jun 6 01:00:00 EDT 2006

e$B:#$N$H$3$m!"e(BTime
e$B$N$3$H$O9M$($F$^$;$s$,!“9)IW$9$l$P!”<c43$N=u$1$K$O$Je(B
e$B$k$G$7$g$&$+!#e(B

Time.mktime(2000) +
(Date4::Delta.nanoseconds(1234567890).in_seconds.to_f)
#=> 2000-01-01 00:00:01 +0900

active_support e$B$N$h$&$J$3$H$O!“e(Bdate3
e$B$G$A$g$C$H$d$C$?$s$G$9$,!”<u$1F~e(B
[email protected]$m$&$H;W$C$F$9$0;_$a$F$7$^$$$^$7$?!#e(B

ActiveSupporte$B$K$"$ke(BNumerice$B$N3HD%$O%@%a$G$9$+e(B??
e$B8D?ME*[email protected]$H;W$&$N$G$9$,!#e(B

1.week.since(DateTime)e$B$J$I$J$I!#e(B

Tietew e$B$5$s$O=q$-$^$7$?e(B:

ActiveSupporte$B$G;w$F$$$k$h$&$J3HD%$,$"$k!#e(B
Time#advancee$B$G$9!#e(B

Time.now.advance(:days => 1)
=> Sat Dec 29 12:13:06 +0900 2007

Time.now.advance(:months => 1)
=> Mon Jan 28 12:13:12 +0900 2008

Time.now.advance(:hours => 1)
=> Fri Dec 28 13:13:16 +0900 2007

DateTimee$B$be(BDatee$B$be(BOKe$B$G$9!#e(B

DateTime.now.advance(:hours => 1)
=> Fri, 28 Dec 2007 13:13:20 +0900

DateTime.now.advance(:days => 1)
=> Sat, 29 Dec 2007 12:13:27 +0900

Date.today.advance(:days => 1)
=> Sat, 29 Dec 2007

On Thu, 27 Dec 2007 22:08:23 +0900
In article [email protected]
[[ruby-dev:32827] Re: class TimeSpan]
e$BM73Z0Ce(B [email protected] wrote:

ActiveSupporte$B$K$"$ke(BNumerice$B$N3HD%$O%@%a$G$9$+e(B??
e$B8D?ME*[email protected]$H;W$&$N$G$9$,!#e(B

1.week.since(DateTime)e$B$J$I$J$I!#e(B

e$BL5M}$G$9$h!#e(B
irb(main):015:0> 1.week.since(DateTime.now).to_s
=> “3663-11-16T10:36:11+09:00”
irb(main):016:0> 1.week.since(Time.now).to_s
=> “Fri Jan 04 10:36:32 +0900 2008”

e$B$"$H!"e(B

1.month e$B$O0l%v7n$G$O$J$/$Fe(B30e$BF|$G$9$7!#e(B
1.year e$B$O0lG/$G$O$J$/$Fe(B365e$BF|$G$9$7!#e(B

irb(main):008:0> Time.local(2004,1,1)+1.year
=> Fri Dec 31 06:00:00 +0900 2004

[email protected]@%$G$9!#e(B

Tietew wrote:

TimeSpan e$B$N$h$&$J%/%i%9$rDI2C$9$k$H0J2<$N$h$&$K$J$C$F8m2r$,>/$J$/$J$k$Ne(B
e$B$G$9$,!"$$$+$,$G$7$g$&$+!#e(B

:month(s), :year(s) e$B$,M_$7$/$J$j$^$9$M$(!#e(B

months e$B$de(B years e$B$Oe(B days
e$B$+$i%j%K%"$KA}$d$;$J$$$N$G%W%m%H%?%$%W$G$O$d$a$Fe(B
e$B$*$-$^$7$?!#e(B30days e$B$de(B 365days
[email protected]$H%@%a$G$9$7$M!#<B:]$K$OI,MW$G$7$g$&$M!#e(B

weeks e$B$O>o$Ke(B7e$BF|$+!#e(B

Date e$B$Oe(B << >> e$B$G%5%]!<%H$7$F$^$9$M!#e(B
Date.today >> 1 # => 2008-01-27

e$B$&$&$s!"$3$l$O$I$&$J$s$G$7$g$&$M!#e(B

[email protected]@%$G$9!#e(B

Tadayoshi F. wrote:

require ‘date4/timezone/posix’

EST = Date4::TimeZone::POSIX.new(‘EST5EDT,M4.1.0,M10.5.0’)
dt = DateTime4.new(2006,6,6,:tz=>EST)
dt += Date4::Delta.parse(’-(2 fortnights - 1 hour * 673)’)
puts dt.strftime(’%+’) # Tue Jun 6 01:00:00 EDT 2006

e$B$$)!"$$$$$G$9$M!#$3$A$i!"<[email protected]$H$J$C$F$$$^$9$,!"e(B1.9
e$B$G$H$je(B
e$B$3$a$J$$$N$G$9$+$M!#e(B

e$B:#$N$H$3$m!"e(BTime e$B$N$3$H$O9M$($F$^$;$s$,!“9)IW$9$l$P!”<c43$N=u$1$K$O$Je(B
e$B$k$G$7$g$&$+!#e(B

Time.mktime(2000) + (Date4::Delta.nanoseconds(1234567890).in_seconds.to_f)
#=> 2000-01-01 00:00:01 +0900

Time e$B$,e(B other.to_f e$B$NA0$Ke(B other.in_seconds e$B$J$j$r8+$Fe(B
to_f e$B$9$k$N$,%Y%9e(B
e$B%H$+$J$!$H;W$C$F$$$^$9!#%Q%C%A$G$Oe(B Time
e$B$K$^$G<j$rF~$l$k$N$,LLE][email protected]$C$?$Ne(B
e$B$GN,$7$^$7$?$,!#e(B

active_support e$B$N$h$&$J$3$H$O!“e(Bdate3 e$B$G$A$g$C$H$d$C$?$s$G$9$,!”<u$1F~e(B
[email protected]$m$&$H;W$C$F$9$0;_$a$F$7$^$$$^$7$?!#e(B

Railse$BE*$K$O%"%j$J$N$G$7$g$&$,!“e(BRubye$BE*$K$O$J$s$+0c$&$H$$$&$+!”$^$D$b$H$5e(B
e$B$s$,%@%[email protected]$$$=$&$J$s$G$9$h$M!#e(B

[email protected]@%$G$9!#e(B

e$BM73Z0Ce(B wrote:

ActiveSupporte$B$K$"$ke(BNumerice$B$N3HD%$O%@%a$G$9$+e(B??
e$B8D?ME*[email protected]$H;W$&$N$G$9$,!#e(B

1.week.since(DateTime)e$B$J$I$J$I!#e(B

e$BJXMx$J$N$O$o$+$k$N$G$9$,!"e(BNumeric
e$B$r3HD%$9$k$H$$$&H/A[$,$J$s$+0c$&$h$&$Je(B
e$B5$$,$7$^$9!#$$$d!“e(B0x61.chr e$B$H$+$b$”$j$^$9$1$I!#e(B

ActiveSupport [email protected]$He(B 1.month == 30.days e$B$J$N$b$A$g$C$H!#e(B

e$B4V0c$$$^$7$?!#$9$_$^$;$s!#e(B

Tietew e$B$5$s$O=q$-$^$7$?e(B:

e$BL5M}$G$9$h!#e(B
irb(main):015:0> 1.week.since(DateTime.now).to_s
=> “3663-11-16T10:36:11+09:00”
irb(main):016:0> 1.week.since(Time.now).to_s
=> “Fri Jan 04 10:36:32 +0900 2008”

e$B$=$&!"e(BNumeric#sincee$B$N0z?t$Oe(BDateTimee$B$G$O$J$/$Fe(BTimee$B$G$7$?$M!#e(B

e$B$"$H!"e(B

1.month e$B$O0l%v7n$G$O$J$/$Fe(B30e$BF|$G$9$7!#e(B
1.year e$B$O0lG/$G$O$J$/$Fe(B365e$BF|$G$9$7!#e(B

irb(main):008:0> Time.local(2004,1,1)+1.year
=> Fri Dec 31 06:00:00 +0900 2004

e$B$3$l$Oe(BActiveSupporte$B$N%I%-%e%a%s%H$K$b!V$d$k$J!W$H=q$$$F$"$j$^$9!#e(B
e$B!Ve(Bweeke$B!W0J2<$J$i$3$l$b%"%j$+$H;W$$$^$7$?!#e(B

[email protected]@%$G$9!#e(B

Leonard C. wrote:

DateTimee$B$be(BDatee$B$be(BOKe$B$G$9!#e(B

DateTime.now.advance(:hours => 1)
=> Fri, 28 Dec 2007 13:13:20 +0900

DateTime.now.advance(:days => 1)
=> Sat, 29 Dec 2007 12:13:27 +0900

Date.today.advance(:days => 1)
=> Sat, 29 Dec 2007

e$B$"!<!"$3$l$OCN$j$^$;$s$G$7$?!#$+$J$j6a$$$H;W$$$^$9!#e(B
e$B$"$([email protected]$&$J$i$P!"e(B+ e$B$G$J$/e(B advance
e$B$J$3$H$d!“0z?t$,4|4V%*%V%8%’%/%H$G$Je(B
e$B$/[email protected]$N%O%C%7%e$J$”$?$j$G$7$g$&$+!#e(B

e$B4|4V%*%V%8%’%/%H$C$F$"$^$j;H$o$l$J$$$N$+$J$!!#$o$?$7$O?tCM$G4|4V$r<h$j$^e(B
e$B$o$9$N$C$FIT0B$J$N$G$9$,!#e(B

e$BM73Z0C$G$9!#e(B

e$B;d$be(BTimeSpane$B%*%V%8%’%/%H<+BN!"$$$$$H;W$$$^$9!#e(B
[email protected]!“Nc$($P!Ve(B1e$BG/8e!W$H$+!Ve(B1e$B=54V8e!W$H$+$r%9%+%C$H=q$-$?$$$H$$$&M_5a$be(B
e$B$”$k$N$G$9!#e(B
e$B:#$+$ie(B1e$BG/8e$NF|IU$r=P$9$N$Ke(B

TimeSpan.new(:year => 1).since(Time.now)

e$B$C$F!"$J$s$+!Ve(BJavae$B$_$?$$$G%d%@!W$H$$$&$o$,$^$^$G$9$M!#e(B

e$B$b$C$H$b!"e(BTimeSpane$B%/%i%9$rA0Ds$K$9$l$Pe(B
e$B$=$l$rJV$9$h$&$Ke(BNumeric#year_spane$B$H$+E,Ev$K:n$C$Fe(B

2.year_span.since(Time.now)

e$B$H$+=q$1$k$h$&$K$7$A$c$($P$$$$$3$H$G$9!#e(B

TimeSpan#to_hashe$B$r:n$C$F!"e(BActiveSupporte$B$Ne(BTime#advancee$B$K7R$2$k$H$+$7$?$ie(B
e$B%7%s%?%C%/%9%7%e%,!<$H$7$FF0:n$7$^$9$7!"e(B
e$B;H$&B&$,<qL#$d>u67$K9g$o$;$F;H$$J,$1$k$3$H$b$G$-$=$&$G$9!#e(B
ActiveSupporte$BA0Ds$GOC$r$9$k$H0[[email protected]$,B?$/=P$=$&$G$9$,!#e(B

NARUSE, Yui e$B$5$s$O=q$-$^$7$?e(B:

e$B$$)!"$$$$$G$9$M!#$3$A$i!"<[email protected]$H$J$C$F$$$^$9$,!"e(B1.9 e$B$G$H$je(B
e$B$3$a$J$$$N$G$9$+$M!#e(B

e$B$_$s$J$,G<[email protected]$G$-$k;EMM$H<[email protected]'Hs$=$&$7$?$$$G$9!#e(B

Time e$B$,e(B other.to_f e$B$NA0$Ke(B other.in_seconds e$B$J$j$r8+$Fe(B to_f e$B$9$k$N$,%Y%9e(B
e$B%H$+$J$!$H;W$C$F$$$^$9!#%Q%C%A$G$Oe(B Time e$B$K$^$G<j$rF~$l$k$N$,LLE][email protected]$C$?$Ne(B
e$B$GN,$7$^$7$?$,!#e(B

e$B$H$j$"$($:!"e(BDelta e$B$N$[$&$O0l2U=jD>$7$F!"e(B

class Time

alias_method :plus_orig, :+
alias_method :minus_orig, :-

private :plus_orig, :minus_orig

def + (n)
case n
when Numeric; return plus_orig(n)
else
l, r = n.coerce(self)
return l + r
end
end

(e$B0J2<N,e(B)

e$B$N$h$&$K$9$l$P!"e(BTime e$B$K$b$D$+$($=$&$G$9!#e(B

e$B;d$be(BTimeSpane$B%*%V%8%’%/%H<+BN!"$$$$$H;W$$$^$9!#e(B
[email protected]!“Nc$($P!Ve(B1e$BG/8e!W$H$+!Ve(B1e$B=54V8e!W$H$+$r%9%+%C$H=q$-$?$$$H$$$&M_5a$be(B
e$B$”$k$N$G$9!#e(B

active_support e$B$r0-$$$H$O$$$$$^$;$s!#e(BTime.now.yesterday
e$B$H$+!"$A$g$C$He(B
e$B%"%l$G$9$,!#e(B

ruby
e$B0lBN$K$=$&[email protected]$H$$$&$3$H$J$i!"$A$g$C$HH=$j$^$;$s!#e(B10e$B%,%m%s$Ce(B
e$B$F%9%+$C$H=q$-$?$$?M$b$$$k$G$7$g$&!#e(B"/etc/motd".open e$B$H$+!"e(B
“2001-02-03”.to_date e$B$H$+!“e(B[2001,2,3].mktime
e$B$H$+!”$I$s$I$sDI2C$7$F$$$Ce(B
e$B$?$[$&$,$$$$$s$G$7$g$&$+!#e(B

e$B$"$k$$$O!";~4V$d;~9o$OFCJL$J$s$G$7$g$&$+!#e(B

e$B$=$l$O$H$b$+$/!"!Ve(B1e$BG/8e!W$d!Ve(B1e$BG/4V!W$J$I$O!“J8L.$K0MB8$9$k$N$G!”$$$:$le(B
e$B$K$7$F$b$"$^$j%9%+$C$H$O=q$1$J$$$N$G!"e(BTimeSpan e$B$de(B Delta
e$B$J$I$H!“0l=o$Ke(B
e$B$7$F$$$$$b$N$+$o$+$j$^$;$s!#$I$A$i$+$H$$$&$H!”!V:rF|!W$H$$$&I=8=$d!"G/e(B
e$B$N$J$$!Ve(B3e$B7ne(B3e$BF|!W$N$h$&$JF|IU$NN`$K;W$$$^$9!#e(B

[email protected]@%$G$9!#e(B

e$BM73Z0Ce(B wrote:

e$BM73Z0C$G$9!#e(B

e$B;d$be(BTimeSpane$B%*%V%8%’%/%H<+BN!"$$$$$H;W$$$^$9!#e(B
[email protected]!“Nc$($P!Ve(B1e$BG/8e!W$H$+!Ve(B1e$B=54V8e!W$H$+$r%9%+%C$H=q$-$?$$$H$$$&M_5a$be(B
e$B$”$k$N$G$9!#e(B
e$B:#$+$ie(B1e$BG/8e$NF|IU$r=P$9$N$Ke(B

TimeSpan.new(:year => 1).since(Time.now)

e$B$C$F!"$J$s$+!Ve(BJavae$B$_$?$$$G%d%@!W$H$$$&$o$,$^$^$G$9$M!#e(B

e$B$=$l$O!"$o$?$7$b%$%d$G$9$M$’!#e(B

Time.now + TimeSpan(:year => 1)

e$B$"[email protected]$H$$A$$A$+$J!<$He(B

e$B$b$C$H$b!"e(BTimeSpane$B%/%i%9$rA0Ds$K$9$l$Pe(B
e$B$=$l$rJV$9$h$&$Ke(BNumeric#year_spane$B$H$+E,Ev$K:n$C$Fe(B

2.year_span.since(Time.now)

e$B$H$+=q$1$k$h$&$K$7$A$c$($P$$$$$3$H$G$9!#e(B

2.years #=> TimeSpan
Time.now + 2.years

e$B$NJ}$,$o$+$j$d$9$$$-$b$7$^$9$,!"$5$F$$-e(B 2.years
e$B$C$FI=5-$,$=$b$=$be(B Ruby
e$BE
$G$O$J$$5$$O$7$^$9!#e(B

TimeSpan#to_hashe$B$r:n$C$F!"e(BActiveSupporte$B$Ne(BTime#advancee$B$K7R$2$k$H$+$7$?$ie(B
e$B%7%s%?%C%/%9%7%e%,!<$H$7$FF0:n$7$^$9$7!"e(B
e$B;H$&B&$,<qL#$d>u67$K9g$o$;$F;H$$J,$1$k$3$H$b$G$-$=$&$G$9!#e(B
ActiveSupporte$BA0Ds$GOC$r$9$k$H0[[email protected]$,B?$/=P$=$&$G$9$,!#e(B

ActiveSupport [email protected]$3&[email protected]$H;W$&$N$G$9$,!"e(BRuby
e$BK\BN$H$O0ce(B
e$B$&5$$,$9$k$N$G$9$h$M!#e(B

Yuguie$B$G$9!#e(B

On 2007/12/28, at 22:50, NARUSE, Yui wrote:

2.years #=> TimeSpan
Time.now + 2.years

e$B$NJ}$,$o$+$j$d$9$$$-$b$7$^$9$,!"$5$F$$-e(B 2.years e$B$C$FI=e(B
e$B5-$,$=$b$=$be(B Ruby
e$BE
$G$O$J$$5$$O$7$^$9!#e(B

e$B;d$be(BActiveSupporte$BIwI=5-$NF3F~$K$O0cOB46$r46$8$^$9!#[email protected]!“e(B
Rubye$BE*$G$J$$$+$He(B
e$B$$$&$H$=$&$b;W$o$J$$$G$9!#e(B2.timese$B$b$”$k$7!"e(B2.chre$B$b$"e(B
e$B$j$^$9$+$i$M!#e(B

e$B$^$:!";~4V4V3V$r?tCM$GI=$7$F$$$k8=>u$O$d$O$jD>46E*$G$J$/!“e(B
Timee$B$OIC$Ge(BDateTime
e$B$OF|$G!”$H3P$($J$/$F$O$J$i$J$$$N$O2?$+$,4V0c$C$F$k>[email protected]$H$O;W$&e(B
e$B$s$G$9!#e(B
e$B$G$9$+$i!"<+A3$Je(BAPIe$B$,$"$l$Pe(BTimeSpane$B$J$je(BDeltae$B$Je(B
e$B$j$,$"[email protected]$i$7$$$H;W$$$^e(B
e$B$9!#e(B e$BFC$K!"!Ve(B1e$BG/!W$N$h$&$J[#Kf$J35G0$rI=8=$9$k$K$O$=e(B
e$B$l$,K>$^$7$$$G$9$h$M!#e(B

e$B$1$l$I$b!"$=$N$?$a$Ke(BNumerice$B$r3HD%$9$k$N$O0c$C$F!"$=$l$O;~e(B
e$B4V$rB>$N<!85$KBP$7$Fe(B
e$BFC8"E*$K07$&$3$H$J$s$G$9$h$M!#e(B
[email protected]$C$F$b!";~4V4V3V$,DL2_C10L$h$j$b3JJL$K$h$/;H$o$l$ke(B
e$B$b$N$H$O;W$($:!#e(B

e$B%W%j%%F%#%V$J?tNL35G0e(B(Numeric)e$B$r%3%"$K$7$J$,$i$b!"$=$3$+e(B
e$B$i<!85!&C10LIU$-$NNLe(B
e$B$rF3=P$9$k0lHLE*$J%a%=%C%I$H!"$=$N%a%=%C%I$K<!85$dC10L$rE,MQ$9$ke(B
e$B$?$a$N5,Ls!“e(B
e$B$,$”$l$P$$$$$H;W$$$^$9!#$"$s$^$j6qBNE*$J0F$,=P$F$3$J$/$F62=L$G$9e(B
e$B$,!#e(B
2.
(Year)
2._(Kiro * Meter)
e$B$3$l$G$O$^[email protected]!"$J$s$+$A$g$C$HIT<+A3$G$9$h$M!#e(B
2[Year]
2[Kilo * Meter]
2[Yen]
e$B$3$C$A$N$[$&$,>/$7$^$7$G$7$g$&$+!#e(Bkind_of?e$B$G%S%C%H%"%/%;%9e(B
e$B$HH=JL$O2DG=$G$9$h$M!#e(B

e$B$5$7$"$?$C$F$O!"e(BActiveSupporte$B$N$h$&$Je(Bad-hoce$B$J2r7h$re(B
e$B%i%$%V%i%j$G<B8=$G$-$k$N$Oe(B
[email protected][email protected]$G!"e(BActiveSupporte$B7A<0$r;~4V$KBP$7$F$N$_e(B
Rubye$B<+BN$K<BAu$9$ke(B
e$BI,[email protected]$O46$8$^$;$s!#e(B
e$B<!85$KBP$7$FCfN)$Je:No$Je(BAPIe$B$,;W$$Ib$+$Y$PAGE([email protected]$H;W$&$s$Ge(B
e$B$9$,!#$&!<$s!#e(B
2[Year]
e$B$O$I$&$G$9$+$M!#e(B

e$BM73Z0C$G$9!#e(B

2[Year]
e$B$O$I$&$G$9$+$M!#e(B

2[Year][email protected]$H!Ve(BYeare$B!W$r$I$3$+$KDj?tDj5A$7$J$1$l$P$$$1$J$/$J$k$N$Ge(B
e$B$J$i$P%7%s%%k$G!Ve(B2[:year]e$B!W$H$$$&$N$O$I$&$G$7$g$&!#e(B

e$B!D$H$+=q$$$F$F!"$=$3$^$G:Y$+$$$3$H$O$I$&$G$b$($(5$$,$7$F$-$^$7$?!#e(B
2.yeare$B$be(B2[:year]e$B$de(B2[Year]e$B$b8+$F$/$l;w$F$^$9$7$M!#e(B
[email protected][email protected]$7$C$Z$J$N$K$9$_$^$;$s!#e(B

[email protected]$H;W$$$^$9!#e(B

e$B$^$:!";~4V4V3V$r?tCM$GI=$7$F$$$k8=>u$O$d$O$jD>46E*$G$J$/!“e(BTimee$B$OIC$Ge(B
DateTime
e$B$OF|$G!”$H3P$($J$/$F$O$J$i$J$$$N$O2?$+$,4V0c$C$F$k>[email protected]$H$O;W$&$s$G$9!#e(B

Rubye$B;O$a$?:"$+$i;W$C$F$?$s$G$9$,!"$=$b$=$b$J$s$GF|IU!&;~4V$rI=$9%/%i%9$,e(B
e$B!Ve(BDatee$B!W!Ve(BTimee$B!W!Ve(BDateTimee$B!W$He(B3e$B$D$b$"$k$N$G$7$g$&$+!#e(B
e$B!Ve(BDatee$B!W$d!Ve(BDateTimee$B!W$K$G$-$F!Ve(BTimee$B!W$K$G$-$J$$$3$H$O$J$$$H;W$&$s$G$9$he(B
e$B$M!#$b$A$m$s;~4VC10L$OJL$G$9$,!#e(B

e$B;[email protected]$1$NLdBj$J$i$P!"$=$l$3$=!Ve(B1.daye$B!W$J$j!Ve(B1[:day]e$B!W$d!Ve(B1[Day]e$B!W$Ge(B
e$B$b$J$s$G$be(BNumerice$B$NJ}[email protected]$7$F!Ve(BTimee$B!W$KJ|$j9~$`$h$&$K$9$l$Pe(B
e$B3P$($k$3$H$,8:$C$F!";d$N$h$&$K!Ve(B1.week.since()e$B!W$Ke(BDateTimee$B%*%V%8%’%/%H$re(B
e$BEO$7$Fe(B1000e$BG/8e$NF|IU$r=P$7$F$7$^$&$h$&$J%I%8$O8:$k$h$&$K;W$&$N$G$9$,!#e(B

Yugui e$B$5$s$O=q$-$^$7$?e(B:

TimeSpan e$B$N$h$&$J%/%i%9$rDI2C$9$k$H0J2<$N$h$&$K$J$C$F8m2r$,>/$J$/$J$k$Ne(B
e$B$G$9$,!"$$$+$,$G$7$g$&$+!#e(B

e$B$3$s$K$A$O!#e(B
[ruby-list:44398]e$B$Ge(BDateTimee$B$N2C;;$K$D$$$F<[email protected]>Ec$G$9!#e(B
e$BOCBj$K;22C$5$;$F2<$5$$!#e(B

e$B8=:_!"8f65<xD:$$$?e(BActiveSupporte$B$r;HMQ$7$F$$$^$9!#e(B
e$B8+1I$($bNI$$$7!"8e$+$i%=!<%9FI$s$G$b2?$,$7$?$$$+0lL\NFA3$J$N$G$9$,!"2??M$NJ}$,6D$C$F$kMM$KA4BNE*$K8+$k$H0cOB46$,M-$j$^$9!#e(B

Railse$B4D6-$J$i0cOB46$OL5$$$N$G$7$g$&$,!"Hse(BRailse$B4D6-$Ke([email protected]$1<h$j9~$s$G;[email protected][email protected]$3&$H$$$&$+!&!&!&e(B

e$B$^$?!"0lG/$,C1=c$Ke(B365e$BF|$G$O$^$:$$>[email protected]$,I,[email protected]$H;W$&$N$G$9$,!"e(BNumerice$B%/%i%9$K2?$G$bG$$;$FNI$$$N$+5?Ld$G$9!#e(B

e$B$d$O$j!“e(B
TimeSpane$B%/%i%9$NMM$JF|IU!&;~4V$rCj>]2=$7$F$/$l$k%/%i%9$,5o$F!“2C;;!&8:;;BP>]$,2?$G$”$le(BTimeSpane$B%*%V%8%’%/%H$rEO$7$F$”$2$5$($9$l$PLdBj2r7h!“e(B
[email protected]$&$N$O;H$&B&$+$i$9$l$P3P$($d$9$/$F$”$j$,$?$$$G$9!#e(B

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs