Class: VagrantPlugins::DevCommands::Model::Chain
- Inherits:
-
Object
- Object
- VagrantPlugins::DevCommands::Model::Chain
- Defined in:
- lib/vagrant/devcommands/model/chain.rb
Overview
Definition of an executable command chain
Instance Attribute Summary collapse
-
#commands ⇒ Object
readonly
Returns the value of attribute commands.
-
#desc ⇒ Object
readonly
Returns the value of attribute desc.
-
#help ⇒ Object
readonly
Returns the value of attribute help.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#usage ⇒ Object
readonly
Returns the value of attribute usage.
Instance Method Summary collapse
- #break_on_error? ⇒ Boolean
-
#initialize(spec) ⇒ Chain
constructor
A new instance of Chain.
Constructor Details
#initialize(spec) ⇒ Chain
Returns a new instance of Chain.
13 14 15 16 17 18 19 20 21 22 |
# File 'lib/vagrant/devcommands/model/chain.rb', line 13 def initialize(spec) @name = spec[:name] @commands = spec[:commands] @desc = spec[:desc] @help = spec[:help] @usage = spec[:usage] @break_on_error = spec[:break_on_error] != false end |
Instance Attribute Details
#commands ⇒ Object (readonly)
Returns the value of attribute commands.
7 8 9 |
# File 'lib/vagrant/devcommands/model/chain.rb', line 7 def commands @commands end |
#desc ⇒ Object (readonly)
Returns the value of attribute desc.
9 10 11 |
# File 'lib/vagrant/devcommands/model/chain.rb', line 9 def desc @desc end |
#help ⇒ Object (readonly)
Returns the value of attribute help.
10 11 12 |
# File 'lib/vagrant/devcommands/model/chain.rb', line 10 def help @help end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
6 7 8 |
# File 'lib/vagrant/devcommands/model/chain.rb', line 6 def name @name end |
#usage ⇒ Object (readonly)
Returns the value of attribute usage.
11 12 13 |
# File 'lib/vagrant/devcommands/model/chain.rb', line 11 def usage @usage end |
Instance Method Details
#break_on_error? ⇒ Boolean
24 25 26 |
# File 'lib/vagrant/devcommands/model/chain.rb', line 24 def break_on_error? @break_on_error end |