Class: ConvenientService::Common::Plugins::HasInternals::Commands::CreateInternalsClass

Inherits:
Support::Command
  • Object
show all
Includes:
Support::DependencyContainer::Import
Defined in:
lib/convenient_service/common/plugins/has_internals/commands/create_internals_class.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Support::Concern

included

Methods inherited from Support::Command

[], call

Constructor Details

#initialize(entity_class:) ⇒ void

Parameters:

  • entity_class (Class)


26
27
28
# File 'lib/convenient_service/common/plugins/has_internals/commands/create_internals_class.rb', line 26

def initialize(entity_class:)
  @entity_class = entity_class
end

Instance Attribute Details

#entity_classObject (readonly)

Returns the value of attribute entity_class.



15
16
17
# File 'lib/convenient_service/common/plugins/has_internals/commands/create_internals_class.rb', line 15

def entity_class
  @entity_class
end

Instance Method Details

#callClass

Returns:

  • (Class)


33
34
35
# File 'lib/convenient_service/common/plugins/has_internals/commands/create_internals_class.rb', line 33

def call
  commands.FindOrCreateEntity.call(namespace: entity_class, proto_entity: Entities::Internals)
end