Class: Hermeneutics::Timestamp
- Inherits:
-
Time
- Object
- Time
- Hermeneutics::Timestamp
- Defined in:
- lib/hermeneutics/types.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.new(time = nil) ⇒ Object
42 43 44 45 46 47 48 |
# File 'lib/hermeneutics/types.rb', line 42 def new time = nil case time when nil then now when Time then mktime *time.to_a else parse time.to_s end end |
Instance Method Details
#encode ⇒ Object
53 54 55 |
# File 'lib/hermeneutics/types.rb', line 53 def encode rfc822 end |
#quote ⇒ Object
50 51 52 |
# File 'lib/hermeneutics/types.rb', line 50 def quote to_s end |