Sha256: 5865118af18cb035a9fc44a075bb6834e6bbe40ac6c91ca8dc507dc0e661ccae

Contents?: true

Size: 502 Bytes

Versions: 22

Compression:

Stored size: 502 Bytes

Contents

# frozen_string_literal: true

module PlatformosCheck
  module LanguageServer
    class DocumentLinkEngine
      def initialize(storage)
        @storage = storage
        @providers = DocumentLinkProvider.all.map { |x| x.new(storage) }
      end

      def document_links(relative_path)
        buffer = @storage.read(relative_path)
        return [] unless buffer

        @providers.flat_map do |p|
          p.document_links(buffer, @storage.platformos_app)
        end
      end
    end
  end
end

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
platformos-check-0.4.14 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.13 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.12 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.11 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.10 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.9 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.8 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.7 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.6 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.5 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.4 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.3 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.2 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.1 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.4.0 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.3.3 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.3.1 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.3.0 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.2.2 lib/platformos_check/language_server/document_link_engine.rb
platformos-check-0.2.1 lib/platformos_check/language_server/document_link_engine.rb