lib/purecloudplatformclientv2/models/analytics_participant.rb in purecloudplatformclientv2-8.0.0 vs lib/purecloudplatformclientv2/models/analytics_participant.rb in purecloudplatformclientv2-9.0.0
- old
+ new
@@ -33,30 +33,46 @@
attr_accessor :sessions
# Attribute mapping from ruby-style variable name to JSON key.
def self.attribute_map
{
+
:'participant_id' => :'participantId',
+
:'participant_name' => :'participantName',
+
:'user_id' => :'userId',
+
:'purpose' => :'purpose',
+
:'external_contact_id' => :'externalContactId',
+
:'external_organization_id' => :'externalOrganizationId',
+
:'sessions' => :'sessions'
+
}
end
# Attribute type mapping.
def self.swagger_types
{
+
:'participant_id' => :'String',
+
:'participant_name' => :'String',
+
:'user_id' => :'String',
+
:'purpose' => :'String',
+
:'external_contact_id' => :'String',
+
:'external_organization_id' => :'String',
+
:'sessions' => :'Array<AnalyticsSession>'
+
}
end
# Initializes the object
# @param [Hash] attributes Model attributes in the form of hash
@@ -64,67 +80,170 @@
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?(:'participantId')
+
+
self.participant_id = attributes[:'participantId']
+
+
end
+
if attributes.has_key?(:'participantName')
+
+
self.participant_name = attributes[:'participantName']
+
+
end
+
if attributes.has_key?(:'userId')
+
+
self.user_id = attributes[:'userId']
+
+
end
+
if attributes.has_key?(:'purpose')
+
+
self.purpose = attributes[:'purpose']
+
+
end
+
if attributes.has_key?(:'externalContactId')
+
+
self.external_contact_id = attributes[:'externalContactId']
+
+
end
+
if attributes.has_key?(:'externalOrganizationId')
+
+
self.external_organization_id = attributes[:'externalOrganizationId']
+
+
end
+
if attributes.has_key?(:'sessions')
+
if (value = attributes[:'sessions']).is_a?(Array)
self.sessions = value
end
+
+
+
end
+
end
# Show invalid properties with the reasons. Usually used together with valid?
# @return Array for valid properies with the reasons
def list_invalid_properties
invalid_properties = Array.new
+
+
return invalid_properties
end
# Check to see if the all the properties in the model are valid
# @return true if the model is valid
def valid?
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
allowed_values = ["manual", "dialer", "inbound", "acd", "ivr", "voicemail", "outbound", "agent", "user", "station", "group", "customer", "external"]
if @purpose && !allowed_values.include?(@purpose)
return false
end
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
end
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
# Custom attribute writer method checking allowed values (enum).
# @param [Object] purpose Object to be assigned
def purpose=(purpose)
allowed_values = ["manual", "dialer", "inbound", "acd", "ivr", "voicemail", "outbound", "agent", "user", "station", "group", "customer", "external"]
if purpose && !allowed_values.include?(purpose)
fail ArgumentError, "invalid value for 'purpose', must be one of #{allowed_values}."
end
@purpose = purpose
end
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
# Checks equality by comparing each attribute.
# @param [Object] Object to be compared
def ==(o)
return true if self.equal?(o)
self.class == o.class &&