/*
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
 * in compliance with the License. You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software distributed under the License
 * 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.
 */
/*
 * This code was generated by https://github.com/googleapis/google-api-java-client-services/
 * Modify at your own risk.
 */

package com.google.api.services.dialogflow.v2beta1.model;

/**
 * Represents a conversation participant (human agent, virtual agent, end-user).
 *
 * <p> This is the Java data model class that specifies how to parse/serialize into the JSON that is
 * transmitted over HTTP when working with the Dialogflow API. For a detailed explanation see:
 * <a href="https://developers.google.com/api-client-library/java/google-http-java-client/json">https://developers.google.com/api-client-library/java/google-http-java-client/json</a>
 * </p>
 *
 * @author Google, Inc.
 */
@SuppressWarnings("javadoc")
public final class GoogleCloudDialogflowV2beta1Participant extends com.google.api.client.json.GenericJson {

  /**
   * Optional. Key-value filters on the metadata of documents returned by article suggestion. If
   * specified, article suggestion only returns suggested documents that match all filters in their
   * Document.metadata. Multiple values for a metadata key should be concatenated by comma. For
   * example, filters to match all documents that have 'US' or 'CA' in their market metadata values
   * and 'agent' in their user metadata values will be ``` documents_metadata_filters { key:
   * "market" value: "US,CA" } documents_metadata_filters { key: "user" value: "agent" } ```
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.util.Map<String, java.lang.String> documentsMetadataFilters;

  /**
   * Optional. The unique identifier of this participant. Format:
   * `projects//locations//conversations//participants/`.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String name;

  /**
   * Optional. Obfuscated user id that should be associated with the created participant. You can
   * specify a user id as follows: 1. If you set this field in CreateParticipantRequest or
   * UpdateParticipantRequest, Dialogflow adds the obfuscated user id with the participant. 2. If
   * you set this field in AnalyzeContent or StreamingAnalyzeContent, Dialogflow will update
   * Participant.obfuscated_external_user_id. Dialogflow uses this user id for following purposes:
   * 1) Billing and measurement. If user with the same obfuscated_external_user_id is created in a
   * later conversation, dialogflow will know it's the same user. 2) Agent assist suggestion
   * personalization. For example, Dialogflow can use it to provide personalized smart reply
   * suggestions for this user. Note: * Please never pass raw user ids to Dialogflow. Always
   * obfuscate your user id first. * Dialogflow only accepts a UTF-8 encoded string, e.g., a hex
   * digest of a hash function like SHA-512. * The length of the user id must be <= 256 characters.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String obfuscatedExternalUserId;

  /**
   * Immutable. The role this participant plays in the conversation. This field must be set during
   * participant creation and is then immutable.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String role;

  /**
   * Optional. Key-value filters on the metadata of documents returned by article suggestion. If
   * specified, article suggestion only returns suggested documents that match all filters in their
   * Document.metadata. Multiple values for a metadata key should be concatenated by comma. For
   * example, filters to match all documents that have 'US' or 'CA' in their market metadata values
   * and 'agent' in their user metadata values will be ``` documents_metadata_filters { key:
   * "market" value: "US,CA" } documents_metadata_filters { key: "user" value: "agent" } ```
   * @return value or {@code null} for none
   */
  public java.util.Map<String, java.lang.String> getDocumentsMetadataFilters() {
    return documentsMetadataFilters;
  }

  /**
   * Optional. Key-value filters on the metadata of documents returned by article suggestion. If
   * specified, article suggestion only returns suggested documents that match all filters in their
   * Document.metadata. Multiple values for a metadata key should be concatenated by comma. For
   * example, filters to match all documents that have 'US' or 'CA' in their market metadata values
   * and 'agent' in their user metadata values will be ``` documents_metadata_filters { key:
   * "market" value: "US,CA" } documents_metadata_filters { key: "user" value: "agent" } ```
   * @param documentsMetadataFilters documentsMetadataFilters or {@code null} for none
   */
  public GoogleCloudDialogflowV2beta1Participant setDocumentsMetadataFilters(java.util.Map<String, java.lang.String> documentsMetadataFilters) {
    this.documentsMetadataFilters = documentsMetadataFilters;
    return this;
  }

  /**
   * Optional. The unique identifier of this participant. Format:
   * `projects//locations//conversations//participants/`.
   * @return value or {@code null} for none
   */
  public java.lang.String getName() {
    return name;
  }

  /**
   * Optional. The unique identifier of this participant. Format:
   * `projects//locations//conversations//participants/`.
   * @param name name or {@code null} for none
   */
  public GoogleCloudDialogflowV2beta1Participant setName(java.lang.String name) {
    this.name = name;
    return this;
  }

  /**
   * Optional. Obfuscated user id that should be associated with the created participant. You can
   * specify a user id as follows: 1. If you set this field in CreateParticipantRequest or
   * UpdateParticipantRequest, Dialogflow adds the obfuscated user id with the participant. 2. If
   * you set this field in AnalyzeContent or StreamingAnalyzeContent, Dialogflow will update
   * Participant.obfuscated_external_user_id. Dialogflow uses this user id for following purposes:
   * 1) Billing and measurement. If user with the same obfuscated_external_user_id is created in a
   * later conversation, dialogflow will know it's the same user. 2) Agent assist suggestion
   * personalization. For example, Dialogflow can use it to provide personalized smart reply
   * suggestions for this user. Note: * Please never pass raw user ids to Dialogflow. Always
   * obfuscate your user id first. * Dialogflow only accepts a UTF-8 encoded string, e.g., a hex
   * digest of a hash function like SHA-512. * The length of the user id must be <= 256 characters.
   * @return value or {@code null} for none
   */
  public java.lang.String getObfuscatedExternalUserId() {
    return obfuscatedExternalUserId;
  }

  /**
   * Optional. Obfuscated user id that should be associated with the created participant. You can
   * specify a user id as follows: 1. If you set this field in CreateParticipantRequest or
   * UpdateParticipantRequest, Dialogflow adds the obfuscated user id with the participant. 2. If
   * you set this field in AnalyzeContent or StreamingAnalyzeContent, Dialogflow will update
   * Participant.obfuscated_external_user_id. Dialogflow uses this user id for following purposes:
   * 1) Billing and measurement. If user with the same obfuscated_external_user_id is created in a
   * later conversation, dialogflow will know it's the same user. 2) Agent assist suggestion
   * personalization. For example, Dialogflow can use it to provide personalized smart reply
   * suggestions for this user. Note: * Please never pass raw user ids to Dialogflow. Always
   * obfuscate your user id first. * Dialogflow only accepts a UTF-8 encoded string, e.g., a hex
   * digest of a hash function like SHA-512. * The length of the user id must be <= 256 characters.
   * @param obfuscatedExternalUserId obfuscatedExternalUserId or {@code null} for none
   */
  public GoogleCloudDialogflowV2beta1Participant setObfuscatedExternalUserId(java.lang.String obfuscatedExternalUserId) {
    this.obfuscatedExternalUserId = obfuscatedExternalUserId;
    return this;
  }

  /**
   * Immutable. The role this participant plays in the conversation. This field must be set during
   * participant creation and is then immutable.
   * @return value or {@code null} for none
   */
  public java.lang.String getRole() {
    return role;
  }

  /**
   * Immutable. The role this participant plays in the conversation. This field must be set during
   * participant creation and is then immutable.
   * @param role role or {@code null} for none
   */
  public GoogleCloudDialogflowV2beta1Participant setRole(java.lang.String role) {
    this.role = role;
    return this;
  }

  @Override
  public GoogleCloudDialogflowV2beta1Participant set(String fieldName, Object value) {
    return (GoogleCloudDialogflowV2beta1Participant) super.set(fieldName, value);
  }

  @Override
  public GoogleCloudDialogflowV2beta1Participant clone() {
    return (GoogleCloudDialogflowV2beta1Participant) super.clone();
  }

}
