Class: Avm::Registry::ApplicationStereotypes::StereotypeBuilder
- Inherits:
-
Object
- Object
- Avm::Registry::ApplicationStereotypes::StereotypeBuilder
- Defined in:
- lib/avm/registry/application_stereotypes/stereotype_builder.rb
Instance Method Summary collapse
Instance Method Details
#add_object(type, object) ⇒ Object
12 13 14 15 16 17 |
# File 'lib/avm/registry/application_stereotypes/stereotype_builder.rb', line 12 def add_object(type, object) attr_method = "#{type}_class" raise "#{attr_method} is already present" if send(attr_method).present? send("#{attr_method}=", object) end |
#build ⇒ Avm::ApplicationStereotypes::Base
20 21 22 |
# File 'lib/avm/registry/application_stereotypes/stereotype_builder.rb', line 20 def build ::Avm::ApplicationStereotypes::Base.new(namespace_module, instance_class, source_class) end |