class ZoomUs::Models::InlineResponse20031Users

Attributes

calls_receive[RW]

Total number of instant meeting calls received by the user.

calls_send[RW]

Total number of instant meeting calls made by the user.

email[RW]

User email.

emoji_receive[RW]

Total number of emojis received by the user.

emoji_send[RW]

Total number of emojis sent by the user.

files_receive[RW]

Total number of files received by the user.

files_send[RW]

Total number of files sent by the user.

group_receive[RW]

Total number of messages received by the user in channels.

group_send[RW]

Total number of messages sent by the user in channels.

images_receive[RW]

Total number of images received by the user.

images_send[RW]

Total number of images sent by the user.

total_receive[RW]

Total number of messages received by the user.

total_send[RW]

Total number of messages sent by the user.

user_id[RW]

User ID.

user_name[RW]

User display name.

videos_receive[RW]

Total number of video files received by the user.

videos_send[RW]

Total number of video files sent by the user.

voice_receive[RW]

Total number of voice files received by the user.

voice_send[RW]

Total number of voice files sent by the user.

Public Class Methods

attribute_map() click to toggle source

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

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 76
def self.attribute_map
  {
    :'user_id' => :'user_id',
    :'user_name' => :'user_name',
    :'email' => :'email',
    :'total_send' => :'total_send',
    :'total_receive' => :'total_receive',
    :'group_send' => :'group_send',
    :'group_receive' => :'group_receive',
    :'calls_send' => :'calls_send',
    :'calls_receive' => :'calls_receive',
    :'files_send' => :'files_send',
    :'files_receive' => :'files_receive',
    :'images_send' => :'images_send',
    :'images_receive' => :'images_receive',
    :'voice_send' => :'voice_send',
    :'voice_receive' => :'voice_receive',
    :'videos_send' => :'videos_send',
    :'videos_receive' => :'videos_receive',
    :'emoji_send' => :'emoji_send',
    :'emoji_receive' => :'emoji_receive'
  }
end
new(attributes = {}) click to toggle source

Initializes the object @param [Hash] attributes Model attributes in the form of hash

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 127
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?(:'user_id')
    self.user_id = attributes[:'user_id']
  end

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

  if attributes.has_key?(:'emoji_receive')
    self.emoji_receive = attributes[:'emoji_receive']
  end
end
swagger_types() click to toggle source

Attribute type mapping.

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 101
def self.swagger_types
  {
    :'user_id' => :'String',
    :'user_name' => :'String',
    :'email' => :'String',
    :'total_send' => :'Integer',
    :'total_receive' => :'Integer',
    :'group_send' => :'Integer',
    :'group_receive' => :'Integer',
    :'calls_send' => :'Integer',
    :'calls_receive' => :'Integer',
    :'files_send' => :'Integer',
    :'files_receive' => :'Integer',
    :'images_send' => :'Integer',
    :'images_receive' => :'Integer',
    :'voice_send' => :'Integer',
    :'voice_receive' => :'Integer',
    :'videos_send' => :'Integer',
    :'videos_receive' => :'Integer',
    :'emoji_send' => :'Integer',
    :'emoji_receive' => :'Integer'
  }
end

Public Instance Methods

==(o) click to toggle source

Checks equality by comparing each attribute. @param [Object] Object to be compared

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 225
def ==(o)
  return true if self.equal?(o)
  self.class == o.class &&
    user_id == o.user_id &&
    user_name == o.user_name &&
    email == o.email &&
    total_send == o.total_send &&
    total_receive == o.total_receive &&
    group_send == o.group_send &&
    group_receive == o.group_receive &&
    calls_send == o.calls_send &&
    calls_receive == o.calls_receive &&
    files_send == o.files_send &&
    files_receive == o.files_receive &&
    images_send == o.images_send &&
    images_receive == o.images_receive &&
    voice_send == o.voice_send &&
    voice_receive == o.voice_receive &&
    videos_send == o.videos_send &&
    videos_receive == o.videos_receive &&
    emoji_send == o.emoji_send &&
    emoji_receive == o.emoji_receive
end
_deserialize(type, value) click to toggle source

Deserializes the data based on type @param string type Data type @param string value Value to be deserialized @return [Object] Deserialized data

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 285
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) click to toggle source

Outputs non-array value in the form of hash For object, use to_hash. Otherwise, just return the value @param [Object] value Any valid value @return [Hash] Returns the value in the form of hash

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 351
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) click to toggle source

Builds the object from hash @param [Hash] attributes Model attributes in the form of hash @return [Object] Returns the model itself

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 264
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) click to toggle source

@see the `==` method @param [Object] Object to be compared

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 251
def eql?(o)
  self == o
end
hash() click to toggle source

Calculates hash code according to all attributes. @return [Fixnum] Hash code

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 257
def hash
  [user_id, user_name, email, total_send, total_receive, group_send, group_receive, calls_send, calls_receive, files_send, files_receive, images_send, images_receive, voice_send, voice_receive, videos_send, videos_receive, emoji_send, emoji_receive].hash
end
list_invalid_properties() click to toggle source

Show invalid properties with the reasons. Usually used together with valid? @return Array for valid properties with the reasons

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 212
def list_invalid_properties
  invalid_properties = Array.new
  invalid_properties
end
to_body() click to toggle source

to_body is an alias to to_hash (backward compatibility) @return [Hash] Returns the object in the form of hash

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 331
def to_body
  to_hash
end
to_hash() click to toggle source

Returns the object in the form of hash @return [Hash] Returns the object in the form of hash

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 337
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_s() click to toggle source

Returns the string representation of the object @return [String] String presentation of the object

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 325
def to_s
  to_hash.to_s
end
valid?() click to toggle source

Check to see if the all the properties in the model are valid @return true if the model is valid

# File lib/zoom_us/models/inline_response_200_31_users.rb, line 219
def valid?
  true
end