Sha256: 0f54e5be2e7121f9958ca8761e19f2df8e69307c24179db4de24eca09ec74b0d

Contents?: true

Size: 1.41 KB

Versions: 107

Compression:

Stored size: 1.41 KB

Contents

module LanguageServer
  module Protocol
    module Interface
      class SignatureHelpOptions
        def initialize(work_done_progress: nil, trigger_characters: nil, retrigger_characters: nil)
          @attributes = {}

          @attributes[:workDoneProgress] = work_done_progress if work_done_progress
          @attributes[:triggerCharacters] = trigger_characters if trigger_characters
          @attributes[:retriggerCharacters] = retrigger_characters if retrigger_characters

          @attributes.freeze
        end

        # @return [boolean]
        def work_done_progress
          attributes.fetch(:workDoneProgress)
        end

        #
        # The characters that trigger signature help
        # automatically.
        #
        # @return [string[]]
        def trigger_characters
          attributes.fetch(:triggerCharacters)
        end

        #
        # List of characters that re-trigger signature help.
        #
        # These trigger characters are only active when signature help is already
        # showing. All trigger characters are also counted as re-trigger
        # characters.
        #
        # @return [string[]]
        def retrigger_characters
          attributes.fetch(:retriggerCharacters)
        end

        attr_reader :attributes

        def to_hash
          attributes
        end

        def to_json(*args)
          to_hash.to_json(*args)
        end
      end
    end
  end
end

Version data entries

107 entries across 107 versions & 13 rubygems

Version Path
harbr-0.1.64 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.63 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.62 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.61 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.60 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.59 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.58 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.57 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.56 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.55 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.54 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.53 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.52 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.50 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.49 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.48 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.47 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.46 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.45 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb
harbr-0.1.44 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/signature_help_options.rb