Skip to Content Skip to Search

A set of gems from a gem dependencies lockfile.

Methods
F
N

Class Public methods

new(sources)

Creates a new LockSet from the given sources

# File ruby/lib/rubygems/resolver/lock_set.rb, line 12
def initialize(sources)
  super()

  @sources = sources.map do |source|
    Gem::Source::Lock.new source
  end

  @specs = []
end

Instance Public methods

find_all(req)

Returns an Array of IndexSpecification objects matching the DependencyRequest req.

# File ruby/lib/rubygems/resolver/lock_set.rb, line 44
def find_all(req)
  @specs.select do |spec|
    req.match? spec
  end
end