Class: LicenseFinder::CocoaPodsPackage
- Defined in:
- lib/license_finder/packages/cocoa_pods_package.rb
Instance Attribute Summary
Attributes inherited from Package
#authors, #children, #description, #groups, #homepage, #install_path, #license_names_from_spec, #logger, #manual_approval, #name, #parents, #summary, #version
Instance Method Summary collapse
-
#initialize(name, version, license_text, options = {}) ⇒ CocoaPodsPackage
constructor
A new instance of CocoaPodsPackage.
- #licenses_from_spec ⇒ Object
- #package_manager ⇒ Object
- #package_url ⇒ Object
Methods inherited from Package
#<=>, #activations, #approved?, #approved_manually!, #approved_manually?, #decide_on_license, #eql?, #hash, #license_files, license_names_from_standard_spec, #licenses, #licensing, #log_activation, #missing?, #notice_files, #permitted!, #permitted?, #restricted!, #restricted?
Constructor Details
#initialize(name, version, license_text, options = {}) ⇒ CocoaPodsPackage
Returns a new instance of CocoaPodsPackage.
5 6 7 8 |
# File 'lib/license_finder/packages/cocoa_pods_package.rb', line 5 def initialize(name, version, license_text, = {}) super(name, version, ) @license = License.find_by_text(license_text.to_s) end |
Instance Method Details
#licenses_from_spec ⇒ Object
10 11 12 |
# File 'lib/license_finder/packages/cocoa_pods_package.rb', line 10 def licenses_from_spec [@license].compact end |
#package_manager ⇒ Object
14 15 16 |
# File 'lib/license_finder/packages/cocoa_pods_package.rb', line 14 def package_manager 'CocoaPods' end |
#package_url ⇒ Object
18 19 20 |
# File 'lib/license_finder/packages/cocoa_pods_package.rb', line 18 def package_url "https://cocoapods.org/pods/#{CGI.escape(name)}" end |