lib/purecloudplatformclientv2/models/analytics_participant.rb in purecloudplatformclientv2-73.0.0 vs lib/purecloudplatformclientv2/models/analytics_participant.rb in purecloudplatformclientv2-75.0.0

- old
+ new

@@ -22,13 +22,10 @@ attr_accessor :participant_id # A human readable name identifying the participant attr_accessor :participant_name - # List of attributes associated to this participant - attr_accessor :attributes - # If a user, then this will be the unique identifier for the user attr_accessor :user_id # The participant's purpose attr_accessor :purpose @@ -43,32 +40,35 @@ attr_accessor :flagged_reason # List of sessions associated to this participant attr_accessor :sessions + # List of attributes associated to this participant + attr_accessor :attributes + # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { :'participant_id' => :'participantId', :'participant_name' => :'participantName', - :'attributes' => :'attributes', - :'user_id' => :'userId', :'purpose' => :'purpose', :'external_contact_id' => :'externalContactId', :'external_organization_id' => :'externalOrganizationId', :'flagged_reason' => :'flaggedReason', - :'sessions' => :'sessions' + :'sessions' => :'sessions', + :'attributes' => :'attributes' + } end # Attribute type mapping. def self.swagger_types @@ -76,24 +76,24 @@ :'participant_id' => :'String', :'participant_name' => :'String', - :'attributes' => :'Hash<String, String>', - :'user_id' => :'String', :'purpose' => :'String', :'external_contact_id' => :'String', :'external_organization_id' => :'String', :'flagged_reason' => :'String', - :'sessions' => :'Array<AnalyticsSession>' + :'sessions' => :'Array<AnalyticsSession>', + :'attributes' => :'Hash<String, String>' + } end # Initializes the object # @param [Hash] attributes Model attributes in the form of hash @@ -120,21 +120,10 @@ end - if attributes.has_key?(:'attributes') - - if (value = attributes[:'attributes']).is_a?(Array) - self.attributes = value - end - - - - end - - if attributes.has_key?(:'userId') self.user_id = attributes[:'userId'] @@ -187,10 +176,21 @@ end + if attributes.has_key?(:'attributes') + + if (value = attributes[:'attributes']).is_a?(Array) + self.attributes = 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 @@ -216,14 +216,10 @@ - - - - allowed_values = ["manual", "dialer", "inbound", "acd", "ivr", "voicemail", "outbound", "agent", "user", "station", "group", "customer", "external", "fax", "workflow", "campaign", "api"] if @purpose && !allowed_values.include?(@purpose) return false end @@ -248,10 +244,14 @@ + + + + end @@ -267,15 +267,10 @@ - - - - - # 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", "fax", "workflow", "campaign", "api"] if purpose && !allowed_values.include?(purpose) @@ -314,24 +309,29 @@ + + + + + # Checks equality by comparing each attribute. # @param [Object] Object to be compared def ==(o) return true if self.equal?(o) self.class == o.class && participant_id == o.participant_id && participant_name == o.participant_name && - attributes == o.attributes && user_id == o.user_id && purpose == o.purpose && external_contact_id == o.external_contact_id && external_organization_id == o.external_organization_id && flagged_reason == o.flagged_reason && - sessions == o.sessions + sessions == o.sessions && + attributes == o.attributes end # @see the `==` method # @param [Object] Object to be compared def eql?(o) @@ -339,10 +339,10 @@ end # Calculates hash code according to all attributes. # @return [Fixnum] Hash code def hash - [participant_id, participant_name, attributes, user_id, purpose, external_contact_id, external_organization_id, flagged_reason, sessions].hash + [participant_id, participant_name, user_id, purpose, external_contact_id, external_organization_id, flagged_reason, sessions, attributes].hash end # build the object from hash def build_from_hash(attributes) return nil unless attributes.is_a?(Hash)