Class: Spandx::Dotnet::NugetGateway
Overview
Instance Method Summary
collapse
#all, #inherited, #registry
Constructor Details
#initialize(http: Spandx.http) ⇒ NugetGateway
Returns a new instance of NugetGateway.
9
10
11
|
# File 'lib/spandx/dotnet/nuget_gateway.rb', line 9
def initialize(http: Spandx.http)
@http = http
end
|
Instance Method Details
#each(start_page: 0) ⇒ Object
21
22
23
24
25
26
27
|
# File 'lib/spandx/dotnet/nuget_gateway.rb', line 21
def each(start_page: 0)
each_page(start_page: start_page) do |page_json|
items_from(page_json).each do |item|
yield(fetch_json(item['@id']), page_number_from(page_json['@id']))
end
end
end
|
#licenses_for(dependency) ⇒ Object
13
14
15
|
# File 'lib/spandx/dotnet/nuget_gateway.rb', line 13
def licenses_for(dependency)
(nuspec_for(dependency.name, dependency.version))
end
|
#matches?(dependency) ⇒ Boolean
17
18
19
|
# File 'lib/spandx/dotnet/nuget_gateway.rb', line 17
def matches?(dependency)
dependency.package_manager == :nuget
end
|