Class: WifiWand::RuntimeConfig
- Inherits:
-
Object
- Object
- WifiWand::RuntimeConfig
- Defined in:
- lib/wifi_wand/runtime_config.rb
Instance Attribute Summary collapse
-
#err_stream ⇒ Object
Returns the value of attribute err_stream.
-
#out_stream ⇒ Object
Returns the value of attribute out_stream.
-
#utc ⇒ Object
Returns the value of attribute utc.
-
#verbose ⇒ Object
Returns the value of attribute verbose.
Instance Method Summary collapse
-
#initialize(verbose: false, utc: false, out_stream: $stdout, err_stream: $stderr) ⇒ RuntimeConfig
constructor
A new instance of RuntimeConfig.
- #to_h ⇒ Object
Constructor Details
#initialize(verbose: false, utc: false, out_stream: $stdout, err_stream: $stderr) ⇒ RuntimeConfig
Returns a new instance of RuntimeConfig.
8 9 10 11 12 13 |
# File 'lib/wifi_wand/runtime_config.rb', line 8 def initialize(verbose: false, utc: false, out_stream: $stdout, err_stream: $stderr) @verbose = !!verbose @utc = !!utc @out_stream = out_stream @err_stream = err_stream end |
Instance Attribute Details
#err_stream ⇒ Object
Returns the value of attribute err_stream.
6 7 8 |
# File 'lib/wifi_wand/runtime_config.rb', line 6 def err_stream @err_stream end |
#out_stream ⇒ Object
Returns the value of attribute out_stream.
6 7 8 |
# File 'lib/wifi_wand/runtime_config.rb', line 6 def out_stream @out_stream end |
#utc ⇒ Object
Returns the value of attribute utc.
5 6 7 |
# File 'lib/wifi_wand/runtime_config.rb', line 5 def utc @utc end |
#verbose ⇒ Object
Returns the value of attribute verbose.
5 6 7 |
# File 'lib/wifi_wand/runtime_config.rb', line 5 def verbose @verbose end |
Instance Method Details
#to_h ⇒ Object
23 24 25 26 27 28 29 30 |
# File 'lib/wifi_wand/runtime_config.rb', line 23 def to_h { verbose: verbose, utc: utc, out_stream: out_stream, err_stream: err_stream, } end |