Class: Bosh::Director::CompiledPackageGroup

Inherits:
Object
  • Object
show all
Defined in:
lib/bosh/director/compiled_package_group.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(release_version, stemcell) ⇒ CompiledPackageGroup

Returns a new instance of CompiledPackageGroup.



3
4
5
6
# File 'lib/bosh/director/compiled_package_group.rb', line 3

def initialize(release_version, stemcell)
  @release_version = release_version
  @stemcell = stemcell
end

Instance Attribute Details

#release_versionObject (readonly)

Returns the value of attribute release_version.



22
23
24
# File 'lib/bosh/director/compiled_package_group.rb', line 22

def release_version
  @release_version
end

Instance Method Details

#compiled_packagesObject



8
9
10
11
12
13
14
15
16
# File 'lib/bosh/director/compiled_package_group.rb', line 8

def compiled_packages
  @compiled_packages ||= @release_version.packages.map do |package|
    Models::CompiledPackage[
      :package_id => package.id,
      :stemcell_id => @stemcell.id,
      :dependency_key => @release_version.package_dependency_key(package.name)
    ]
  end.compact
end

#stemcell_sha1Object



18
19
20
# File 'lib/bosh/director/compiled_package_group.rb', line 18

def stemcell_sha1
  @stemcell.sha1
end