Class: RubyCoded::Commands::PluginProvider

Inherits:
Object
  • Object
show all
Defined in:
lib/ruby_coded/commands/plugin_provider.rb

Overview

Adapts plugin-registered commands to the unified command catalog.

Instance Method Summary collapse

Constructor Details

#initialize(registry:) ⇒ PluginProvider

Returns a new instance of PluginProvider.



9
10
11
# File 'lib/ruby_coded/commands/plugin_provider.rb', line 9

def initialize(registry:)
  @registry = registry
end

Instance Method Details

#definitionsObject



13
14
15
# File 'lib/ruby_coded/commands/plugin_provider.rb', line 13

def definitions
  commands.map { |name, handler| build_definition(name, handler) }
end