Class: Configliere::ParamParent

Inherits:
DeepHash
  • Object
show all
Defined in:
lib/configliere/param.rb

Overview

We want to be able to call super() on these methods in all included models, so we define them in this parent shim class.

Direct Known Subclasses

Param

Constant Summary

Constants inherited from DeepHash

DeepHash::DEEP_MERGER

Instance Method Summary collapse

Methods inherited from DeepHash

#[], #[]=, #assert_valid_keys, #compact, #compact!, #deep_delete, #deep_get, #deep_merge, #deep_merge!, #deep_set, #delete, #extract!, #fetch, #initialize, #key?, #merge, #regular_update, #regular_writer, #reverse_merge, #reverse_merge!, #slice, #slice!, #stringify_keys, #symbolize_keys, #symbolize_keys!, #to_hash, #update, #values_at

Constructor Details

This class inherits a constructor from DeepHash

Instance Method Details

#exportObject

default export method: dup of self



8
9
10
# File 'lib/configliere/param.rb', line 8

def export
  dup.tap{|hsh| hsh.each{|k,v| hsh[k] = v.respond_to?(:export) ? v.export : v } }
end

#resolve!Object

terminate resolution chain

Returns:

  • self



14
15
16
# File 'lib/configliere/param.rb', line 14

def resolve!
  self
end

#validate!Object

terminate validation chain.

Returns:

  • self



20
21
22
# File 'lib/configliere/param.rb', line 20

def validate!
  self
end