Class: Aruba::BasicConfiguration::Option
- Inherits:
 - 
      Object
      
        
- Object
 - Aruba::BasicConfiguration::Option
 
 
- Defined in:
 - lib/aruba/basic_configuration/option.rb
 
Overview
A configuration option
Instance Attribute Summary collapse
- 
  
    
      #default_value  ⇒ Object 
    
    
  
  
  
  
    
      readonly
    
    
  
  
  
  
  
  
    
Returns the value of attribute default_value.
 - 
  
    
      #name  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    
Returns the value of attribute name.
 - 
  
    
      #value  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    
Returns the value of attribute value.
 
Instance Method Summary collapse
- 
  
    
      #==(other)  ⇒ Object 
    
    
  
  
  
  
  
  
  
  
  
    
Compare option.
 - 
  
    
      #initialize(opts = {})  ⇒ Option 
    
    
  
  
  
    constructor
  
  
  
  
  
  
  
    
Create option.
 
Constructor Details
#initialize(opts = {}) ⇒ Option
Create option
      16 17 18 19 20 21 22 23 24 25 26  | 
    
      # File 'lib/aruba/basic_configuration/option.rb', line 16 def initialize(opts = {}) name = opts[:name] value = opts[:value] raise ArgumentError, '"name" is required' unless opts.key? :name raise ArgumentError, '"value" is required' unless opts.key? :value @name = name @value = value @default_value = value end  | 
  
Instance Attribute Details
#default_value ⇒ Object (readonly)
Returns the value of attribute default_value.
      13 14 15  | 
    
      # File 'lib/aruba/basic_configuration/option.rb', line 13 def default_value @default_value end  | 
  
#name ⇒ Object
Returns the value of attribute name.
      12 13 14  | 
    
      # File 'lib/aruba/basic_configuration/option.rb', line 12 def name @name end  | 
  
#value ⇒ Object
Returns the value of attribute value.
      12 13 14  | 
    
      # File 'lib/aruba/basic_configuration/option.rb', line 12 def value @value end  | 
  
Instance Method Details
#==(other) ⇒ Object
Compare option
      29 30 31  | 
    
      # File 'lib/aruba/basic_configuration/option.rb', line 29 def ==(other) name == other.name && value == other.value end  |