Sha256: 83857027760f37e1d4ac503cce6b4cc59028aec3616726e1384ac2f84d64b0b9

Contents?: true

Size: 360 Bytes

Versions: 25

Compression:

Stored size: 360 Bytes

Contents

# frozen_string_literal: true

module PlatformosCheck
  module LanguageServer
    class ExecuteCommandEngine
      def initialize
        @providers = {}
      end

      def <<(provider)
        @providers[provider.command] = provider
      end

      def execute(command, arguments)
        @providers[command].execute(arguments)
      end
    end
  end
end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
platformos-check-0.2.0 lib/platformos_check/language_server/execute_command_engine.rb
platformos-check-0.1.0 lib/platformos_check/language_server/execute_command_engine.rb
platformos-check-0.0.3 lib/platformos_check/language_server/execute_command_engine.rb
platformos-check-0.0.2 lib/platformos_check/language_server/execute_command_engine.rb
platformos-check-0.0.1 lib/platformos_check/language_server/execute_command_engine.rb