Class: SetHotspotAction
- Inherits:
-
ConnectivityAction
- Object
- MacroObject
- Action
- ConnectivityAction
- SetHotspotAction
- Defined in:
- lib/ruby-macrodroid.rb
Instance Attribute Summary
Attributes inherited from Action
Attributes inherited from MacroObject
Instance Method Summary collapse
-
#initialize(h = {}) ⇒ SetHotspotAction
constructor
A new instance of SetHotspotAction.
- #to_s ⇒ Object
Methods inherited from Action
Methods inherited from MacroObject
Constructor Details
#initialize(h = {}) ⇒ SetHotspotAction
Returns a new instance of SetHotspotAction.
2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 |
# File 'lib/ruby-macrodroid.rb', line 2787 def initialize(h={}) = { device_name: "", state: 0, turn_wifi_on: true, use_legacy_mechanism: false, mechanism: 0 } super(.merge h) end |
Instance Method Details
#to_s ⇒ Object
2798 2799 2800 2801 |
# File 'lib/ruby-macrodroid.rb', line 2798 def to_s() action = @h[:turn_wifi_on] ? 'Enable' : 'Disable' action + ' HotSpot' end |