Class: VagrantBoxVersion::Config
- Inherits:
-
Object
- Object
- VagrantBoxVersion::Config
- Defined in:
- lib/vagrant_box_version/config.rb
Instance Attribute Summary collapse
-
#url ⇒ Object
Returns the value of attribute url.
Instance Method Summary collapse
- #finalize! ⇒ Object
-
#initialize ⇒ Config
constructor
A new instance of Config.
- #validate(machine) ⇒ Object
Constructor Details
#initialize ⇒ Config
Returns a new instance of Config.
6 7 8 |
# File 'lib/vagrant_box_version/config.rb', line 6 def initialize() @url = UNSET_VALUE end |
Instance Attribute Details
#url ⇒ Object
Returns the value of attribute url.
4 5 6 |
# File 'lib/vagrant_box_version/config.rb', line 4 def url @url end |
Instance Method Details
#finalize! ⇒ Object
10 11 12 |
# File 'lib/vagrant_box_version/config.rb', line 10 def finalize! @url = "" if @url == UNSET_VALUE end |
#validate(machine) ⇒ Object
14 15 16 17 18 19 20 |
# File 'lib/vagrant_box_version/config.rb', line 14 def validate(machine) if @url.empty? { "version" => ["config.version.url must be set"] } else {} end end |