Class: Teleport::Config::Apt
- Inherits:
-
Object
- Object
- Teleport::Config::Apt
- Defined in:
- lib/teleport/config.rb
Overview
The model for an apt line in the Telfile.
Instance Attribute Summary collapse
-
#line ⇒ Object
readonly
Returns the value of attribute line.
-
#options ⇒ Object
readonly
Returns the value of attribute options.
Instance Method Summary collapse
-
#initialize(line, options) ⇒ Apt
constructor
A new instance of Apt.
Constructor Details
#initialize(line, options) ⇒ Apt
Returns a new instance of Apt.
99 100 101 102 103 104 105 106 107 |
# File 'lib/teleport/config.rb', line 99 def initialize(line, ) raise "apt line must be a string" if !line.is_a?(String) raise "apt options must be a hash" if !.is_a?(Hash) @line, @options = line, if k = @options[:key] raise "apt :key must be an String" if !k.is_a?(String) end end |
Instance Attribute Details
#line ⇒ Object (readonly)
Returns the value of attribute line.
97 98 99 |
# File 'lib/teleport/config.rb', line 97 def line @line end |
#options ⇒ Object (readonly)
Returns the value of attribute options.
97 98 99 |
# File 'lib/teleport/config.rb', line 97 def @options end |