Class: Virtus::Coercion::Array
- Inherits:
-
Object
- Object
- Virtus::Coercion
- Object
- Virtus::Coercion::Array
- Defined in:
- lib/virtus/coercion/array.rb
Overview
Coerce Array values
Constant Summary collapse
- TIME_SEGMENTS =
[ :year, :month, :day, :hour, :min, :sec ].freeze
Constants inherited from Object
Object::COERCION_METHOD_REGEXP
Constants included from TypeLookup
Class Method Summary collapse
-
.to_set(value) ⇒ Array
private
Creates a Set instance from an Array.
Methods inherited from Object
to_array, to_hash, to_integer, to_string
Methods inherited from Virtus::Coercion
Methods included from TypeLookup
#determine_type, extended, #primitive
Methods included from Options
#accept_options, #accepted_options, #options
Class Method Details
.to_set(value) ⇒ Array
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Creates a Set instance from an Array
17 18 19 |
# File 'lib/virtus/coercion/array.rb', line 17 def self.to_set(value) value.to_set end |