Class: Grizzled::Grinc::Parameters
- Inherits:
-
Object
- Object
- Grizzled::Grinc::Parameters
- Defined in:
- lib/grizzled/grinc.rb
Overview
Classes
Instance Attribute Summary collapse
-
#input_paths ⇒ Object
readonly
Returns the value of attribute input_paths.
-
#max_nesting ⇒ Object
readonly
Returns the value of attribute max_nesting.
-
#output ⇒ Object
readonly
Returns the value of attribute output.
Instance Method Summary collapse
-
#initialize(options_hash, argv) ⇒ Parameters
constructor
A new instance of Parameters.
- #method_missing(m, *args, &block) ⇒ Object
- #to_s ⇒ Object
Constructor Details
#initialize(options_hash, argv) ⇒ Parameters
Returns a new instance of Parameters.
65 66 67 68 69 |
# File 'lib/grizzled/grinc.rb', line 65 def initialize(, argv) @options = @options[:max_nesting] = [:max_nesting] || DEFAULT_MAX_NEST @options[:input_paths] = argv.length == 0 ? nil : argv end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(m, *args, &block) ⇒ Object
71 72 73 |
# File 'lib/grizzled/grinc.rb', line 71 def method_missing(m, *args, &block) @options[m] end |
Instance Attribute Details
#input_paths ⇒ Object (readonly)
Returns the value of attribute input_paths.
63 64 65 |
# File 'lib/grizzled/grinc.rb', line 63 def input_paths @input_paths end |
#max_nesting ⇒ Object (readonly)
Returns the value of attribute max_nesting.
63 64 65 |
# File 'lib/grizzled/grinc.rb', line 63 def max_nesting @max_nesting end |
#output ⇒ Object (readonly)
Returns the value of attribute output.
63 64 65 |
# File 'lib/grizzled/grinc.rb', line 63 def output @output end |
Instance Method Details
#to_s ⇒ Object
75 76 77 |
# File 'lib/grizzled/grinc.rb', line 75 def to_s inspect end |