Class: Tramway::Config

Inherits:
Anyway::Config
  • Object
show all
Includes:
Singleton
Defined in:
lib/tramway/config.rb

Overview

Basic configuration of Tramway

Instance Method Summary collapse

Instance Method Details

#entities=(collection) ⇒ Object



19
20
21
22
23
24
25
# File 'lib/tramway/config.rb', line 19

def entities=(collection)
  super(collection.map do |entity|
    entity_options = entity.is_a?(Hash) ? entity : { name: entity }

    Tramway::Configs::Entity.new(**entity_options)
  end)
end