Method: Highway::Steps::Types::Hash#initialize

Defined in:
lib/highway/steps/types/hash.rb

#initialize(element_type, validate: nil) ⇒ Hash

Initialize an instance.

Parameters:

  • element_type (Object)

    Type of inner elements.

  • validate (Proc) (defaults to: nil)

    A custom value validation block.


22
23
24
25
# File 'lib/highway/steps/types/hash.rb', line 22

def initialize(element_type, validate: nil)
  super(validate: validate)
  @element_type = element_type
end