Class: MistApi::WebhookSiteSleEventSle
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- MistApi::WebhookSiteSleEventSle
- Defined in:
- lib/mist_api/models/webhook_site_sle_event_sle.rb
Overview
WebhookSiteSleEventSle Model.
Instance Attribute Summary collapse
-
#ap_availability ⇒ Float
TODO: Write general description for this method.
-
#successful_connect ⇒ Float
TODO: Write general description for this method.
-
#time_to_connect ⇒ Float
TODO: Write general description for this method.
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.
-
.validate(value) ⇒ Object
Validates an instance of the object from a given value.
Instance Method Summary collapse
-
#initialize(ap_availability = SKIP, successful_connect = SKIP, time_to_connect = SKIP) ⇒ WebhookSiteSleEventSle
constructor
A new instance of WebhookSiteSleEventSle.
-
#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(ap_availability = SKIP, successful_connect = SKIP, time_to_connect = SKIP) ⇒ WebhookSiteSleEventSle
Returns a new instance of WebhookSiteSleEventSle.
47 48 49 50 51 52 |
# File 'lib/mist_api/models/webhook_site_sle_event_sle.rb', line 47 def initialize(ap_availability = SKIP, successful_connect = SKIP, time_to_connect = SKIP) @ap_availability = ap_availability unless ap_availability == SKIP @successful_connect = successful_connect unless successful_connect == SKIP @time_to_connect = time_to_connect unless time_to_connect == SKIP end |
Instance Attribute Details
#ap_availability ⇒ Float
TODO: Write general description for this method
14 15 16 |
# File 'lib/mist_api/models/webhook_site_sle_event_sle.rb', line 14 def ap_availability @ap_availability end |
#successful_connect ⇒ Float
TODO: Write general description for this method
18 19 20 |
# File 'lib/mist_api/models/webhook_site_sle_event_sle.rb', line 18 def successful_connect @successful_connect end |
#time_to_connect ⇒ Float
TODO: Write general description for this method
22 23 24 |
# File 'lib/mist_api/models/webhook_site_sle_event_sle.rb', line 22 def time_to_connect @time_to_connect end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 |
# File 'lib/mist_api/models/webhook_site_sle_event_sle.rb', line 55 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. ap_availability = hash.key?('ap-availability') ? hash['ap-availability'] : SKIP successful_connect = hash.key?('successful-connect') ? hash['successful-connect'] : SKIP time_to_connect = hash.key?('time-to-connect') ? hash['time-to-connect'] : SKIP # Create object from extracted values. WebhookSiteSleEventSle.new(ap_availability, successful_connect, time_to_connect) end |
.names ⇒ Object
A mapping from model property names to API property names.
25 26 27 28 29 30 31 |
# File 'lib/mist_api/models/webhook_site_sle_event_sle.rb', line 25 def self.names @_hash = {} if @_hash.nil? @_hash['ap_availability'] = 'ap-availability' @_hash['successful_connect'] = 'successful-connect' @_hash['time_to_connect'] = 'time-to-connect' @_hash end |
.nullables ⇒ Object
An array for nullable fields
43 44 45 |
# File 'lib/mist_api/models/webhook_site_sle_event_sle.rb', line 43 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
34 35 36 37 38 39 40 |
# File 'lib/mist_api/models/webhook_site_sle_event_sle.rb', line 34 def self.optionals %w[ ap_availability successful_connect time_to_connect ] end |
.validate(value) ⇒ Object
Validates an instance of the object from a given value.
74 75 76 77 78 79 80 |
# File 'lib/mist_api/models/webhook_site_sle_event_sle.rb', line 74 def self.validate(value) return true if value.instance_of? self return false unless value.instance_of? Hash true end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
90 91 92 93 94 |
# File 'lib/mist_api/models/webhook_site_sle_event_sle.rb', line 90 def inspect class_name = self.class.name.split('::').last "<#{class_name} ap_availability: #{@ap_availability.inspect}, successful_connect:"\ " #{@successful_connect.inspect}, time_to_connect: #{@time_to_connect.inspect}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
83 84 85 86 87 |
# File 'lib/mist_api/models/webhook_site_sle_event_sle.rb', line 83 def to_s class_name = self.class.name.split('::').last "<#{class_name} ap_availability: #{@ap_availability}, successful_connect:"\ " #{@successful_connect}, time_to_connect: #{@time_to_connect}>" end |