class Build::Dependency::PartialChain
Attributes
dependencies[R]
@attr [Array<Depends>] The list of dependencies that needs to be satisfied.
Public Class Methods
expand(*args)
click to toggle source
An `UnresolvedDependencyError` will be thrown if there are any unresolved dependencies.
# File lib/build/dependency/partial_chain.rb, line 33 def self.expand(*args) chain = self.new(*args) chain.freeze return chain end
new(chain, dependencies)
click to toggle source
Calls superclass method
# File lib/build/dependency/partial_chain.rb, line 41 def initialize(chain, dependencies) super() @chain = chain @dependencies = dependencies.collect{|dependency| Depends[dependency]} expand_top end
Public Instance Methods
freeze()
click to toggle source
Calls superclass method
# File lib/build/dependency/partial_chain.rb, line 62 def freeze return unless frozen? @chain.freeze @dependencies.freeze super end
providers()
click to toggle source
# File lib/build/dependency/partial_chain.rb, line 58 def providers @chain.providers end
selection()
click to toggle source
# File lib/build/dependency/partial_chain.rb, line 51 def selection @chain.selection end
Protected Instance Methods
expand(dependency, parent)
click to toggle source
Calls superclass method
# File lib/build/dependency/partial_chain.rb, line 77 def expand(dependency, parent) unless @dependencies.include?(dependency) return if dependency.private? end super(dependency, parent) end
expand_dependency(dependency, parent)
click to toggle source
# File lib/build/dependency/partial_chain.rb, line 85 def expand_dependency(dependency, parent) @chain.resolved[dependency] end
expand_top()
click to toggle source
# File lib/build/dependency/partial_chain.rb, line 73 def expand_top expand_nested(@dependencies, TOP) end
provision_for(provider, dependency)
click to toggle source
# File lib/build/dependency/partial_chain.rb, line 89 def provision_for(provider, dependency) # @chain.resolved[provider] does work, but it points to the most recently added provision, but we want the provision related to the specific dependency. provider.provision_for(dependency) end