/* * Copyright 2010-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). * You may not use this file except in compliance with the License. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing * permissions and limitations under the License. */ package com.amazonaws.services.connect.model; import java.io.Serializable; /** *

* Metadata information about a contact evaluation. *

*/ public class EvaluationMetadata implements Serializable { /** *

* The identifier of the contact in this instance of Amazon Connect. *

*

* Constraints:
* Length: 1 - 256
*/ private String contactId; /** *

* The Amazon Resource Name (ARN) of the user who last updated the * evaluation. *

*/ private String evaluatorArn; /** *

* The identifier of the agent who performed the contact. *

*

* Constraints:
* Length: 1 - 500
*/ private String contactAgentId; /** *

* The overall score of the contact evaluation. *

*/ private EvaluationScore score; /** *

* The identifier of the contact in this instance of Amazon Connect. *

*

* Constraints:
* Length: 1 - 256
* * @return

* The identifier of the contact in this instance of Amazon Connect. *

*/ public String getContactId() { return contactId; } /** *

* The identifier of the contact in this instance of Amazon Connect. *

*

* Constraints:
* Length: 1 - 256
* * @param contactId

* The identifier of the contact in this instance of Amazon * Connect. *

*/ public void setContactId(String contactId) { this.contactId = contactId; } /** *

* The identifier of the contact in this instance of Amazon Connect. *

*

* Returns a reference to this object so that method calls can be chained * together. *

* Constraints:
* Length: 1 - 256
* * @param contactId

* The identifier of the contact in this instance of Amazon * Connect. *

* @return A reference to this updated object so that method calls can be * chained together. */ public EvaluationMetadata withContactId(String contactId) { this.contactId = contactId; return this; } /** *

* The Amazon Resource Name (ARN) of the user who last updated the * evaluation. *

* * @return

* The Amazon Resource Name (ARN) of the user who last updated the * evaluation. *

*/ public String getEvaluatorArn() { return evaluatorArn; } /** *

* The Amazon Resource Name (ARN) of the user who last updated the * evaluation. *

* * @param evaluatorArn

* The Amazon Resource Name (ARN) of the user who last updated * the evaluation. *

*/ public void setEvaluatorArn(String evaluatorArn) { this.evaluatorArn = evaluatorArn; } /** *

* The Amazon Resource Name (ARN) of the user who last updated the * evaluation. *

*

* Returns a reference to this object so that method calls can be chained * together. * * @param evaluatorArn

* The Amazon Resource Name (ARN) of the user who last updated * the evaluation. *

* @return A reference to this updated object so that method calls can be * chained together. */ public EvaluationMetadata withEvaluatorArn(String evaluatorArn) { this.evaluatorArn = evaluatorArn; return this; } /** *

* The identifier of the agent who performed the contact. *

*

* Constraints:
* Length: 1 - 500
* * @return

* The identifier of the agent who performed the contact. *

*/ public String getContactAgentId() { return contactAgentId; } /** *

* The identifier of the agent who performed the contact. *

*

* Constraints:
* Length: 1 - 500
* * @param contactAgentId

* The identifier of the agent who performed the contact. *

*/ public void setContactAgentId(String contactAgentId) { this.contactAgentId = contactAgentId; } /** *

* The identifier of the agent who performed the contact. *

*

* Returns a reference to this object so that method calls can be chained * together. *

* Constraints:
* Length: 1 - 500
* * @param contactAgentId

* The identifier of the agent who performed the contact. *

* @return A reference to this updated object so that method calls can be * chained together. */ public EvaluationMetadata withContactAgentId(String contactAgentId) { this.contactAgentId = contactAgentId; return this; } /** *

* The overall score of the contact evaluation. *

* * @return

* The overall score of the contact evaluation. *

*/ public EvaluationScore getScore() { return score; } /** *

* The overall score of the contact evaluation. *

* * @param score

* The overall score of the contact evaluation. *

*/ public void setScore(EvaluationScore score) { this.score = score; } /** *

* The overall score of the contact evaluation. *

*

* Returns a reference to this object so that method calls can be chained * together. * * @param score

* The overall score of the contact evaluation. *

* @return A reference to this updated object so that method calls can be * chained together. */ public EvaluationMetadata withScore(EvaluationScore score) { this.score = score; return this; } /** * Returns a string representation of this object; useful for testing and * debugging. * * @return A string representation of this object. * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getContactId() != null) sb.append("ContactId: " + getContactId() + ","); if (getEvaluatorArn() != null) sb.append("EvaluatorArn: " + getEvaluatorArn() + ","); if (getContactAgentId() != null) sb.append("ContactAgentId: " + getContactAgentId() + ","); if (getScore() != null) sb.append("Score: " + getScore()); sb.append("}"); return sb.toString(); } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getContactId() == null) ? 0 : getContactId().hashCode()); hashCode = prime * hashCode + ((getEvaluatorArn() == null) ? 0 : getEvaluatorArn().hashCode()); hashCode = prime * hashCode + ((getContactAgentId() == null) ? 0 : getContactAgentId().hashCode()); hashCode = prime * hashCode + ((getScore() == null) ? 0 : getScore().hashCode()); return hashCode; } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof EvaluationMetadata == false) return false; EvaluationMetadata other = (EvaluationMetadata) obj; if (other.getContactId() == null ^ this.getContactId() == null) return false; if (other.getContactId() != null && other.getContactId().equals(this.getContactId()) == false) return false; if (other.getEvaluatorArn() == null ^ this.getEvaluatorArn() == null) return false; if (other.getEvaluatorArn() != null && other.getEvaluatorArn().equals(this.getEvaluatorArn()) == false) return false; if (other.getContactAgentId() == null ^ this.getContactAgentId() == null) return false; if (other.getContactAgentId() != null && other.getContactAgentId().equals(this.getContactAgentId()) == false) return false; if (other.getScore() == null ^ this.getScore() == null) return false; if (other.getScore() != null && other.getScore().equals(this.getScore()) == false) return false; return true; } }