Class: Pod::Resolver::ResolverSpecification
- Inherits:
-
Object
- Object
- Pod::Resolver::ResolverSpecification
- Defined in:
- lib/cocoapods/resolver.rb
Overview
A small container that wraps a resolved specification for a given target definition. Additional metadata is included here such as if the specification is only used by tests.
Instance Attribute Summary collapse
-
#source ⇒ Source
readonly
The spec repo source the specification came from.
-
#spec ⇒ Specification
readonly
The specification that was resolved.
-
#used_by_tests_only ⇒ Bool
(also: #used_by_tests_only?)
readonly
Whether this resolved specification is only used by tests.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(spec, used_by_tests_only, source) ⇒ ResolverSpecification
constructor
A new instance of ResolverSpecification.
- #name ⇒ Object
- #root ⇒ Object
Constructor Details
#initialize(spec, used_by_tests_only, source) ⇒ ResolverSpecification
Returns a new instance of ResolverSpecification.
32 33 34 35 36 |
# File 'lib/cocoapods/resolver.rb', line 32 def initialize(spec, used_by_tests_only, source) @spec = spec @used_by_tests_only = used_by_tests_only @source = source end |
Instance Attribute Details
#source ⇒ Source (readonly)
Returns the spec repo source the specification came from.
25 26 27 |
# File 'lib/cocoapods/resolver.rb', line 25 def source @source end |
#spec ⇒ Specification (readonly)
Returns the specification that was resolved.
21 22 23 |
# File 'lib/cocoapods/resolver.rb', line 21 def spec @spec end |
#used_by_tests_only ⇒ Bool (readonly) Also known as: used_by_tests_only?
Returns whether this resolved specification is only used by tests.
29 30 31 |
# File 'lib/cocoapods/resolver.rb', line 29 def used_by_tests_only @used_by_tests_only end |
Instance Method Details
#==(other) ⇒ Object
46 47 48 49 50 |
# File 'lib/cocoapods/resolver.rb', line 46 def ==(other) self.class == other && spec == other.spec && used_by_tests_only == other.test_only end |
#name ⇒ Object
38 39 40 |
# File 'lib/cocoapods/resolver.rb', line 38 def name spec.name end |
#root ⇒ Object
42 43 44 |
# File 'lib/cocoapods/resolver.rb', line 42 def root spec.root end |