Class: Everlog::Dom::Value
- Inherits:
-
Object
- Object
- Everlog::Dom::Value
- Defined in:
- lib/everlog/dom/value.rb
Defined Under Namespace
Classes: Animetick, Footer, Github, Hatena, Moves, Twitter, Weather
Instance Method Summary collapse
-
#initialize(response) ⇒ Value
constructor
A new instance of Value.
- #parse_to_His(date) ⇒ Object
Constructor Details
#initialize(response) ⇒ Value
Returns a new instance of Value.
11 12 13 |
# File 'lib/everlog/dom/value.rb', line 11 def initialize(response) @response = response end |
Instance Method Details
#parse_to_His(date) ⇒ Object
15 16 17 |
# File 'lib/everlog/dom/value.rb', line 15 def parse_to_His date date.sub(/\d{4}-\d{2}-\d{2}\ /, '').match(/\d{2}:\d{2}/).to_s end |