Class: Dirwatch::Options::InitParser
- Defined in:
- lib/dirwatch/options/parser.rb
Constant Summary
Constants inherited from Parser
Class Attribute Summary collapse
-
.action ⇒ Object
readonly
Returns the value of attribute action.
-
.command_name ⇒ Object
readonly
Returns the value of attribute command_name.
Attributes inherited from Parser
Instance Method Summary collapse
Methods inherited from Parser
#action, #command_name, from_args, #initialize
Constructor Details
This class inherits a constructor from Dirwatch::Options::Parser
Class Attribute Details
.action ⇒ Object (readonly)
Returns the value of attribute action.
112 113 114 |
# File 'lib/dirwatch/options/parser.rb', line 112 def action @action end |
.command_name ⇒ Object (readonly)
Returns the value of attribute command_name.
112 113 114 |
# File 'lib/dirwatch/options/parser.rb', line 112 def command_name @command_name end |
Instance Method Details
#parse!(args) ⇒ Object
115 116 117 118 119 |
# File 'lib/dirwatch/options/parser.rb', line 115 def parse! args super limit_number_of_args 1, args .template = args.shift if args.any? end |