Class: Dependabot::Cargo::UpdateChecker::LatestVersionFinder
- Inherits:
-
Object
- Object
- Dependabot::Cargo::UpdateChecker::LatestVersionFinder
- Extended by:
- T::Sig
- Defined in:
- lib/dependabot/cargo/update_checker/latest_version_finder.rb
Constant Summary collapse
- CRATES_IO_API =
"https://crates.io/api/v1/crates"
Instance Method Summary collapse
-
#initialize(dependency:, dependency_files:, credentials:, ignored_versions:, raise_on_ignored: false, security_advisories:) ⇒ LatestVersionFinder
constructor
A new instance of LatestVersionFinder.
- #latest_version ⇒ Object
- #lowest_security_fix_version ⇒ Object
Constructor Details
#initialize(dependency:, dependency_files:, credentials:, ignored_versions:, raise_on_ignored: false, security_advisories:) ⇒ LatestVersionFinder
Returns a new instance of LatestVersionFinder.
18 19 20 21 22 23 24 25 26 27 |
# File 'lib/dependabot/cargo/update_checker/latest_version_finder.rb', line 18 def initialize(dependency:, dependency_files:, credentials:, ignored_versions:, raise_on_ignored: false, security_advisories:) @dependency = dependency @dependency_files = dependency_files @credentials = credentials @ignored_versions = ignored_versions @raise_on_ignored = raise_on_ignored @security_advisories = security_advisories end |
Instance Method Details
#latest_version ⇒ Object
29 30 31 |
# File 'lib/dependabot/cargo/update_checker/latest_version_finder.rb', line 29 def latest_version @latest_version ||= fetch_latest_version end |
#lowest_security_fix_version ⇒ Object
33 34 35 |
# File 'lib/dependabot/cargo/update_checker/latest_version_finder.rb', line 33 def lowest_security_fix_version @lowest_security_fix_version ||= fetch_lowest_security_fix_version end |