Class: Ploy::PackageSet
- Inherits:
-
Object
- Object
- Ploy::PackageSet
- Defined in:
- lib/ploy/packageset.rb
Instance Attribute Summary collapse
-
#packages ⇒ Object
Returns the value of attribute packages.
Instance Method Summary collapse
-
#initialize(conf) ⇒ PackageSet
constructor
A new instance of PackageSet.
- #locked? ⇒ Boolean
Constructor Details
#initialize(conf) ⇒ PackageSet
Returns a new instance of PackageSet.
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/ploy/packageset.rb', line 5 def initialize(conf) self.packages = [] conf['packages'].each do |k,v| if (not v) v = {} end self.packages.push Ploy::Package.new( conf['bucket'] || v['bucket'], k, v['branch'] || conf['branch'], v['version'] || conf['version'], v['variant'] || conf['variant'] || nil, v['updatevia'] || conf['updatevia'] || nil ) end @locked = conf['locked'] end |
Instance Attribute Details
#packages ⇒ Object
Returns the value of attribute packages.
3 4 5 |
# File 'lib/ploy/packageset.rb', line 3 def packages @packages end |
Instance Method Details
#locked? ⇒ Boolean
23 24 25 |
# File 'lib/ploy/packageset.rb', line 23 def locked? return @locked ? true : false end |