Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 15 lines (13 sloc) 0.236 kb
a58cb26 Geoffrey Grosenbach Move Time duck punch to a separate file
authored
1 class Time
2 def to_json(*a)
3 {
4 'json_class' => self.class.name,
5 'data' => self.strftime("%Y/%m/%d %H:%M:%S %z")
6 }.to_json(*a)
7 end
8 end
9
10 class Time
11 def self.json_create(o)
12 parse(*o['data'])
13 end
14 end
Something went wrong with that request. Please try again.