Coerce Time values
Creates a Fixnum instance from a Time object
@example
Coercible::Coercion::Time.to_integer(time) # => Fixnum object
@param [Time] value
@return [Fixnum]
@api public
# File lib/coercible/coercer/time.rb, line 34 def to_integer(value) value.to_i end
Passthrough the value
@example
coercer[DateTime].to_time(time) # => Time object
@param [DateTime] value
@return [Date]
@api public
# File lib/coercible/coercer/time.rb, line 20 def to_time(value) value end