Sha256: 47de9b665b8a59c670ab004d83bfbfe9286d836d805de4f781c8b742a79459ea

Contents?: true

Size: 544 Bytes

Versions: 13

Compression:

Stored size: 544 Bytes

Contents

# frozen_string_literal: true

module Unwrappr
  module Researchers
    # Delegate to many researchers, collecting and returning their findings.
    #
    # Implements the `gem_researcher` interface required by the
    # LockFileAnnotator.
    class Composite
      def initialize(*researchers)
        @researchers = researchers
      end

      def research(gem_change, gem_change_info)
        @researchers.reduce(gem_change_info) do |info, researcher|
          researcher.research(gem_change, info)
        end
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
unwrappr-0.8.2 lib/unwrappr/researchers/composite.rb
unwrappr-0.8.1 lib/unwrappr/researchers/composite.rb
unwrappr-0.8.0 lib/unwrappr/researchers/composite.rb
unwrappr-0.7.0 lib/unwrappr/researchers/composite.rb
unwrappr-0.6.0 lib/unwrappr/researchers/composite.rb
unwrappr-0.5.0 lib/unwrappr/researchers/composite.rb
unwrappr-0.4.0 lib/unwrappr/researchers/composite.rb
unwrappr-0.3.5 lib/unwrappr/researchers/composite.rb
unwrappr-0.3.4 lib/unwrappr/researchers/composite.rb
unwrappr-0.3.3 lib/unwrappr/researchers/composite.rb
unwrappr-0.3.2 lib/unwrappr/researchers/composite.rb
unwrappr-0.3.1 lib/unwrappr/researchers/composite.rb
unwrappr-0.3.0 lib/unwrappr/researchers/composite.rb