Class: MistApi::ResponseDeviceRadioChannels
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- MistApi::ResponseDeviceRadioChannels
- Defined in:
- lib/mist_api/models/response_device_radio_channels.rb
Overview
ResponseDeviceRadioChannels Model.
Instance Attribute Summary collapse
-
#band24_40mhz_allowed ⇒ TrueClass | FalseClass
TODO: Write general description for this method.
-
#band24_channels ⇒ Array[Integer]
Property key is the channel width.
-
#band24_enabled ⇒ TrueClass | FalseClass
Property key is the channel width.
-
#band5_channels ⇒ Array[Integer]
Property key is the channel width.
-
#band5_enabled ⇒ TrueClass | FalseClass
Property key is the channel width.
-
#band6_channels ⇒ Array[Integer]
Property key is the channel width.
-
#band6_enabled ⇒ TrueClass | FalseClass
Property key is the channel width.
-
#certified ⇒ TrueClass | FalseClass
Property key is the channel width.
-
#code ⇒ Integer
Property key is the channel width.
-
#dfs_ok ⇒ TrueClass | FalseClass
Property key is the channel width.
-
#key ⇒ String
Property key is the channel width.
-
#name ⇒ String
Property key is the channel width.
-
#uses ⇒ String
Property key is the channel width.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(band24_40mhz_allowed = nil, band24_channels = nil, band24_enabled = nil, band5_channels = nil, band5_enabled = nil, certified = nil, code = nil, dfs_ok = nil, key = nil, name = nil, uses = nil, band6_channels = SKIP, band6_enabled = SKIP) ⇒ ResponseDeviceRadioChannels
constructor
A new instance of ResponseDeviceRadioChannels.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(band24_40mhz_allowed = nil, band24_channels = nil, band24_enabled = nil, band5_channels = nil, band5_enabled = nil, certified = nil, code = nil, dfs_ok = nil, key = nil, name = nil, uses = nil, band6_channels = SKIP, band6_enabled = SKIP) ⇒ ResponseDeviceRadioChannels
Returns a new instance of ResponseDeviceRadioChannels.
96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 96 def initialize(band24_40mhz_allowed = nil, band24_channels = nil, band24_enabled = nil, band5_channels = nil, band5_enabled = nil, certified = nil, code = nil, dfs_ok = nil, key = nil, name = nil, uses = nil, band6_channels = SKIP, band6_enabled = SKIP) @band24_40mhz_allowed = band24_40mhz_allowed @band24_channels = band24_channels @band24_enabled = band24_enabled @band5_channels = band5_channels @band5_enabled = band5_enabled @band6_channels = band6_channels unless band6_channels == SKIP @band6_enabled = band6_enabled unless band6_enabled == SKIP @certified = certified @code = code @dfs_ok = dfs_ok @key = key @name = name @uses = uses end |
Instance Attribute Details
#band24_40mhz_allowed ⇒ TrueClass | FalseClass
TODO: Write general description for this method
14 15 16 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 14 def band24_40mhz_allowed @band24_40mhz_allowed end |
#band24_channels ⇒ Array[Integer]
Property key is the channel width
18 19 20 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 18 def band24_channels @band24_channels end |
#band24_enabled ⇒ TrueClass | FalseClass
Property key is the channel width
22 23 24 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 22 def band24_enabled @band24_enabled end |
#band5_channels ⇒ Array[Integer]
Property key is the channel width
26 27 28 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 26 def band5_channels @band5_channels end |
#band5_enabled ⇒ TrueClass | FalseClass
Property key is the channel width
30 31 32 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 30 def band5_enabled @band5_enabled end |
#band6_channels ⇒ Array[Integer]
Property key is the channel width
34 35 36 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 34 def band6_channels @band6_channels end |
#band6_enabled ⇒ TrueClass | FalseClass
Property key is the channel width
38 39 40 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 38 def band6_enabled @band6_enabled end |
#certified ⇒ TrueClass | FalseClass
Property key is the channel width
42 43 44 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 42 def certified @certified end |
#code ⇒ Integer
Property key is the channel width
46 47 48 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 46 def code @code end |
#dfs_ok ⇒ TrueClass | FalseClass
Property key is the channel width
50 51 52 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 50 def dfs_ok @dfs_ok end |
#key ⇒ String
Property key is the channel width
54 55 56 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 54 def key @key end |
#name ⇒ String
Property key is the channel width
58 59 60 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 58 def name @name end |
#uses ⇒ String
Property key is the channel width
62 63 64 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 62 def uses @uses end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 117 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. band24_40mhz_allowed = hash.key?('band24_40mhz_allowed') ? hash['band24_40mhz_allowed'] : nil band24_channels = hash.key?('band24_channels') ? hash['band24_channels'] : nil band24_enabled = hash.key?('band24_enabled') ? hash['band24_enabled'] : nil band5_channels = hash.key?('band5_channels') ? hash['band5_channels'] : nil band5_enabled = hash.key?('band5_enabled') ? hash['band5_enabled'] : nil certified = hash.key?('certified') ? hash['certified'] : nil code = hash.key?('code') ? hash['code'] : nil dfs_ok = hash.key?('dfs_ok') ? hash['dfs_ok'] : nil key = hash.key?('key') ? hash['key'] : nil name = hash.key?('name') ? hash['name'] : nil uses = hash.key?('uses') ? hash['uses'] : nil band6_channels = hash.key?('band6_channels') ? hash['band6_channels'] : SKIP band6_enabled = hash.key?('band6_enabled') ? hash['band6_enabled'] : SKIP # Create object from extracted values. ResponseDeviceRadioChannels.new(band24_40mhz_allowed, band24_channels, band24_enabled, band5_channels, band5_enabled, certified, code, dfs_ok, key, name, uses, band6_channels, band6_enabled) end |
.names ⇒ Object
A mapping from model property names to API property names.
65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 65 def self.names @_hash = {} if @_hash.nil? @_hash['band24_40mhz_allowed'] = 'band24_40mhz_allowed' @_hash['band24_channels'] = 'band24_channels' @_hash['band24_enabled'] = 'band24_enabled' @_hash['band5_channels'] = 'band5_channels' @_hash['band5_enabled'] = 'band5_enabled' @_hash['band6_channels'] = 'band6_channels' @_hash['band6_enabled'] = 'band6_enabled' @_hash['certified'] = 'certified' @_hash['code'] = 'code' @_hash['dfs_ok'] = 'dfs_ok' @_hash['key'] = 'key' @_hash['name'] = 'name' @_hash['uses'] = 'uses' @_hash end |
.nullables ⇒ Object
An array for nullable fields
92 93 94 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 92 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
84 85 86 87 88 89 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 84 def self.optionals %w[ band6_channels band6_enabled ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
167 168 169 170 171 172 173 174 175 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 167 def inspect class_name = self.class.name.split('::').last "<#{class_name} band24_40mhz_allowed: #{@band24_40mhz_allowed.inspect}, band24_channels:"\ " #{@band24_channels.inspect}, band24_enabled: #{@band24_enabled.inspect}, band5_channels:"\ " #{@band5_channels.inspect}, band5_enabled: #{@band5_enabled.inspect}, band6_channels:"\ " #{@band6_channels.inspect}, band6_enabled: #{@band6_enabled.inspect}, certified:"\ " #{@certified.inspect}, code: #{@code.inspect}, dfs_ok: #{@dfs_ok.inspect}, key:"\ " #{@key.inspect}, name: #{@name.inspect}, uses: #{@uses.inspect}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
157 158 159 160 161 162 163 164 |
# File 'lib/mist_api/models/response_device_radio_channels.rb', line 157 def to_s class_name = self.class.name.split('::').last "<#{class_name} band24_40mhz_allowed: #{@band24_40mhz_allowed}, band24_channels:"\ " #{@band24_channels}, band24_enabled: #{@band24_enabled}, band5_channels:"\ " #{@band5_channels}, band5_enabled: #{@band5_enabled}, band6_channels: #{@band6_channels},"\ " band6_enabled: #{@band6_enabled}, certified: #{@certified}, code: #{@code}, dfs_ok:"\ " #{@dfs_ok}, key: #{@key}, name: #{@name}, uses: #{@uses}>" end |