Sha256: 1e1e743a770f3ab564697f6cb7fc49ddf01409d9219f7107a46fb1e66d5c3507

Contents?: true

Size: 1.24 KB

Versions: 111

Compression:

Stored size: 1.24 KB

Contents

module LanguageServer
  module Protocol
    module Interface
      class WorkspaceFoldersServerCapabilities
        def initialize(supported: nil, change_notifications: nil)
          @attributes = {}

          @attributes[:supported] = supported if supported
          @attributes[:changeNotifications] = change_notifications if change_notifications

          @attributes.freeze
        end

        #
        # The server has support for workspace folders
        #
        # @return [boolean]
        def supported
          attributes.fetch(:supported)
        end

        #
        # Whether the server wants to receive workspace folder
        # change notifications.
        #
        # If a string is provided, the string is treated as an ID
        # under which the notification is registered on the client
        # side. The ID can be used to unregister for these events
        # using the `client/unregisterCapability` request.
        #
        # @return [string | boolean]
        def change_notifications
          attributes.fetch(:changeNotifications)
        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

111 entries across 111 versions & 13 rubygems

Version Path
harbr-0.1.84 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.83 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.82 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.81 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.80 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.79 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.78 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.77 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.76 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.75 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.74 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.73 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.72 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.71 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.70 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.69 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.68 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.67 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.66 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb
harbr-0.1.65 vendor/bundle/ruby/3.2.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/interface/workspace_folders_server_capabilities.rb