Class: ZoomUs::Models::WebinarMetrics

Inherits:
Object
  • Object
show all
Defined in:
lib/zoom_us/models/webinar_metrics.rb

Overview

Webinar metric details.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ WebinarMetrics

Initializes the object



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
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
# File 'lib/zoom_us/models/webinar_metrics.rb', line 123

def initialize(attributes = {})
  return unless attributes.is_a?(Hash)

  # convert string to symbol for hash key
  attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }

  if attributes.has_key?(:'uuid')
    self.uuid = attributes[:'uuid']
  end

  if attributes.has_key?(:'id')
    self.id = attributes[:'id']
  end

  if attributes.has_key?(:'topic')
    self.topic = attributes[:'topic']
  end

  if attributes.has_key?(:'host')
    self.host = attributes[:'host']
  end

  if attributes.has_key?(:'email')
    self.email = attributes[:'email']
  end

  if attributes.has_key?(:'user_type')
    self.user_type = attributes[:'user_type']
  end

  if attributes.has_key?(:'start_time')
    self.start_time = attributes[:'start_time']
  end

  if attributes.has_key?(:'end_time')
    self.end_time = attributes[:'end_time']
  end

  if attributes.has_key?(:'duration')
    self.duration = attributes[:'duration']
  end

  if attributes.has_key?(:'participants')
    self.participants = attributes[:'participants']
  end

  if attributes.has_key?(:'has_pstn')
    self.has_pstn = attributes[:'has_pstn']
  end

  if attributes.has_key?(:'has_voip')
    self.has_voip = attributes[:'has_voip']
  end

  if attributes.has_key?(:'has_3rd_party_audio')
    self.has_3rd_party_audio = attributes[:'has_3rd_party_audio']
  end

  if attributes.has_key?(:'has_video')
    self.has_video = attributes[:'has_video']
  end

  if attributes.has_key?(:'has_screen_share')
    self.has_screen_share = attributes[:'has_screen_share']
  end

  if attributes.has_key?(:'has_recording')
    self.has_recording = attributes[:'has_recording']
  end

  if attributes.has_key?(:'has_sip')
    self.has_sip = attributes[:'has_sip']
  end

  if attributes.has_key?(:'dept')
    self.dept = attributes[:'dept']
  end
end

Instance Attribute Details

#deptObject

Department of the host.



71
72
73
# File 'lib/zoom_us/models/webinar_metrics.rb', line 71

def dept
  @dept
end

#durationObject

Webinar duration.



44
45
46
# File 'lib/zoom_us/models/webinar_metrics.rb', line 44

def duration
  @duration
end

#emailObject

User email.



32
33
34
# File 'lib/zoom_us/models/webinar_metrics.rb', line 32

def email
  @email
end

#end_timeObject

Webinar end time.



41
42
43
# File 'lib/zoom_us/models/webinar_metrics.rb', line 41

def end_time
  @end_time
end

#has_3rd_party_audioObject

Indicates whether or not TSP was used for the Webinar.



56
57
58
# File 'lib/zoom_us/models/webinar_metrics.rb', line 56

def has_3rd_party_audio
  @has_3rd_party_audio
end

#has_pstnObject

Indicates whether or not PSTN was used for the Webinar.



50
51
52
# File 'lib/zoom_us/models/webinar_metrics.rb', line 50

def has_pstn
  @has_pstn
end

#has_recordingObject

Indicates whether or not recording was used for the Webinar.



65
66
67
# File 'lib/zoom_us/models/webinar_metrics.rb', line 65

def has_recording
  @has_recording
end

#has_screen_shareObject

Indicates whether or not screen sharing was used for the Webinar.



62
63
64
# File 'lib/zoom_us/models/webinar_metrics.rb', line 62

def has_screen_share
  @has_screen_share
end

#has_sipObject

Indicates whether or not SIP was used for the Webinar.



68
69
70
# File 'lib/zoom_us/models/webinar_metrics.rb', line 68

def has_sip
  @has_sip
end

#has_videoObject

Indicates whether or not video was used for the Webinar.



59
60
61
# File 'lib/zoom_us/models/webinar_metrics.rb', line 59

def has_video
  @has_video
end

#has_voipObject

Indicates whether or not VoIP was used for the Webinar.



53
54
55
# File 'lib/zoom_us/models/webinar_metrics.rb', line 53

def has_voip
  @has_voip
end

#hostObject

User display name.



29
30
31
# File 'lib/zoom_us/models/webinar_metrics.rb', line 29

def host
  @host
end

#idObject

Webinar ID.



23
24
25
# File 'lib/zoom_us/models/webinar_metrics.rb', line 23

def id
  @id
end

#participantsObject

Webinar participant count.



47
48
49
# File 'lib/zoom_us/models/webinar_metrics.rb', line 47

def participants
  @participants
end

#start_timeObject

Webinar start time.



38
39
40
# File 'lib/zoom_us/models/webinar_metrics.rb', line 38

def start_time
  @start_time
end

#topicObject

Webinar topic.



26
27
28
# File 'lib/zoom_us/models/webinar_metrics.rb', line 26

def topic
  @topic
end

#user_typeObject

User type.



35
36
37
# File 'lib/zoom_us/models/webinar_metrics.rb', line 35

def user_type
  @user_type
end

#uuidObject

Webinar UUID.



20
21
22
# File 'lib/zoom_us/models/webinar_metrics.rb', line 20

def uuid
  @uuid
end

Class Method Details

.attribute_mapObject

Attribute mapping from ruby-style variable name to JSON key.



74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
# File 'lib/zoom_us/models/webinar_metrics.rb', line 74

def self.attribute_map
  {
    :'uuid' => :'uuid',
    :'id' => :'id',
    :'topic' => :'topic',
    :'host' => :'host',
    :'email' => :'email',
    :'user_type' => :'user_type',
    :'start_time' => :'start_time',
    :'end_time' => :'end_time',
    :'duration' => :'duration',
    :'participants' => :'participants',
    :'has_pstn' => :'has_pstn',
    :'has_voip' => :'has_voip',
    :'has_3rd_party_audio' => :'has_3rd_party_audio',
    :'has_video' => :'has_video',
    :'has_screen_share' => :'has_screen_share',
    :'has_recording' => :'has_recording',
    :'has_sip' => :'has_sip',
    :'dept' => :'dept'
  }
end

.swagger_typesObject

Attribute type mapping.



98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
# File 'lib/zoom_us/models/webinar_metrics.rb', line 98

def self.swagger_types
  {
    :'uuid' => :'String',
    :'id' => :'Integer',
    :'topic' => :'String',
    :'host' => :'String',
    :'email' => :'String',
    :'user_type' => :'String',
    :'start_time' => :'DateTime',
    :'end_time' => :'DateTime',
    :'duration' => :'String',
    :'participants' => :'Integer',
    :'has_pstn' => :'BOOLEAN',
    :'has_voip' => :'BOOLEAN',
    :'has_3rd_party_audio' => :'BOOLEAN',
    :'has_video' => :'BOOLEAN',
    :'has_screen_share' => :'BOOLEAN',
    :'has_recording' => :'BOOLEAN',
    :'has_sip' => :'BOOLEAN',
    :'dept' => :'String'
  }
end

Instance Method Details

#==(o) ⇒ Object

Checks equality by comparing each attribute.



217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
# File 'lib/zoom_us/models/webinar_metrics.rb', line 217

def ==(o)
  return true if self.equal?(o)
  self.class == o.class &&
    uuid == o.uuid &&
    id == o.id &&
    topic == o.topic &&
    host == o.host &&
    email == o.email &&
    user_type == o.user_type &&
    start_time == o.start_time &&
    end_time == o.end_time &&
    duration == o.duration &&
    participants == o.participants &&
    has_pstn == o.has_pstn &&
    has_voip == o.has_voip &&
    has_3rd_party_audio == o.has_3rd_party_audio &&
    has_video == o.has_video &&
    has_screen_share == o.has_screen_share &&
    has_recording == o.has_recording &&
    has_sip == o.has_sip &&
    dept == o.dept
end

#_deserialize(type, value) ⇒ Object

Deserializes the data based on type



276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
# File 'lib/zoom_us/models/webinar_metrics.rb', line 276

def _deserialize(type, value)
  case type.to_sym
  when :DateTime
    ::DateTime.parse(value)
  when :Date
    ::Date.parse(value)
  when :String
    value.to_s
  when :Integer
    value.to_i
  when :Float
    value.to_f
  when :BOOLEAN
    if value.to_s =~ /\A(true|t|yes|y|1)\z/i
      true
    else
      false
    end
  when :Object
    # generic object (usually a Hash), return directly
    value
  when /\AArray<(?<inner_type>.+)>\z/
    inner_type = Regexp.last_match[:inner_type]
    value.map { |v| _deserialize(inner_type, v) }
  when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
    k_type = Regexp.last_match[:k_type]
    v_type = Regexp.last_match[:v_type]
    {}.tap do |hash|
      value.each do |k, v|
        hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
      end
    end
  else # model
    temp_model = Models.const_get(type).new
    temp_model.build_from_hash(value)
  end
end

#_to_hash(value) ⇒ Hash

Outputs non-array value in the form of hash For object, use to_hash. Otherwise, just return the value



342
343
344
345
346
347
348
349
350
351
352
353
354
# File 'lib/zoom_us/models/webinar_metrics.rb', line 342

def _to_hash(value)
  if value.is_a?(Array)
    value.compact.map { |v| _to_hash(v) }
  elsif value.is_a?(Hash)
    {}.tap do |hash|
      value.each { |k, v| hash[k] = _to_hash(v) }
    end
  elsif value.respond_to? :to_hash
    value.to_hash
  else
    value
  end
end

#build_from_hash(attributes) ⇒ Object

Builds the object from hash



255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
# File 'lib/zoom_us/models/webinar_metrics.rb', line 255

def build_from_hash(attributes)
  return nil unless attributes.is_a?(Hash)
  self.class.swagger_types.each_pair do |key, type|
    if type =~ /\AArray<(.*)>/i
      # check to ensure the input is an array given that the the attribute
      # is documented as an array but the input is not
      if attributes[self.class.attribute_map[key]].is_a?(Array)
        self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
      end
    elsif !attributes[self.class.attribute_map[key]].nil?
      self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
    end # or else data not found in attributes(hash), not an issue as the data can be optional
  end

  self
end

#eql?(o) ⇒ Boolean

See Also:

  • `==` method


242
243
244
# File 'lib/zoom_us/models/webinar_metrics.rb', line 242

def eql?(o)
  self == o
end

#hashFixnum

Calculates hash code according to all attributes.



248
249
250
# File 'lib/zoom_us/models/webinar_metrics.rb', line 248

def hash
  [uuid, id, topic, host, email, user_type, start_time, end_time, duration, participants, has_pstn, has_voip, has_3rd_party_audio, has_video, has_screen_share, has_recording, has_sip, dept].hash
end

#list_invalid_propertiesObject

Show invalid properties with the reasons. Usually used together with valid?



204
205
206
207
# File 'lib/zoom_us/models/webinar_metrics.rb', line 204

def list_invalid_properties
  invalid_properties = Array.new
  invalid_properties
end

#to_bodyHash

to_body is an alias to to_hash (backward compatibility)



322
323
324
# File 'lib/zoom_us/models/webinar_metrics.rb', line 322

def to_body
  to_hash
end

#to_hashHash

Returns the object in the form of hash



328
329
330
331
332
333
334
335
336
# File 'lib/zoom_us/models/webinar_metrics.rb', line 328

def to_hash
  hash = {}
  self.class.attribute_map.each_pair do |attr, param|
    value = self.send(attr)
    next if value.nil?
    hash[param] = _to_hash(value)
  end
  hash
end

#to_sString

Returns the string representation of the object



316
317
318
# File 'lib/zoom_us/models/webinar_metrics.rb', line 316

def to_s
  to_hash.to_s
end

#valid?Boolean

Check to see if the all the properties in the model are valid



211
212
213
# File 'lib/zoom_us/models/webinar_metrics.rb', line 211

def valid?
  true
end