Class used to build the mirror set and then find a mirror for a given URI
@param prober [Prober object, nil] by default a TCPSocketProbe, this object
will be used to probe the mirror address to validate that the mirror replies.
# File bundler/mirror.rb, line 30
def each
@mirrors.each do |k, v|
yield k, v.uri.to_s
end
end
Returns a mirror for the given uri.
Depending on the uri having a valid mirror or not, it may be a
mirror that points to the provided uri
# File bundler/mirror.rb, line 22
def for(uri)
if @all.validate!(@prober).valid?
@all
else
fetch_valid_mirror_for(Settings.normalize_uri(uri))
end
end