Sha256: ccc62898a6d52c77018351e33f82565d20d8d3812e85aa03888d009c6a1c515a

Contents?: true

Size: 736 Bytes

Versions: 142

Compression:

Stored size: 736 Bytes

Contents

module Eco
  module API
    class Session
      class Config
        class BaseConfig < Hash
          
          attr_reader :config

          def initialize(config:)
            super(nil)
            @config = config
          end

          def clone(config:)
            keys.each_with_object(self.class.new(config: config)) do |key, cnf|
              begin
                cnf[key] = self[key].clone(config: cnf)
              rescue ArgumentError
                begin
                  cnf[key] = self[key].clone
                rescue TypeError
                  cnf[key] = self[key]
                end
              end
            end
          end

        end
      end
    end
  end
end

Version data entries

142 entries across 142 versions & 1 rubygems

Version Path
eco-helpers-2.0.40 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.39 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.38 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.37 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.36 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.35 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.34 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.33 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.32 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.31 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.30 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.29 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.28 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.27 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.26 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.25 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.24 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.23 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.22 lib/eco/api/session/config/base_config.rb
eco-helpers-2.0.21 lib/eco/api/session/config/base_config.rb