Class: Yandex::Webmaster::Api::Attributes::Types::Time
- Defined in:
- lib/yandex-webmaster/api/attributes/types/time.rb
Class Method Summary collapse
Methods inherited from Base
default_reader_aliases, default_writer_aliases
Class Method Details
.typecast(value, options = {}) ⇒ Object
9 10 11 |
# File 'lib/yandex-webmaster/api/attributes/types/time.rb', line 9 def self.typecast(value, = {}) [:format].present? ? ::Time.strftime(value, [:format]) : ::Time.parse(value) end |