/*
 * Cloudera Manager API
 * <h1>Cloudera Manager API v57</h1>       <p>Introduced in Cloudera Manager 7.13.1</p>       <p><a href=\"http://www.cloudera.com/documentation.html\">Cloudera Product Documentation</a></p>
 *
 * OpenAPI spec version: 7.13.1
 * 
 *
 * NOTE: This class is auto generated by the swagger code generator program.
 * https://github.com/swagger-api/swagger-codegen.git
 * Do not edit the class manually.
 */

package com.cloudera.api.swagger.model;

import java.util.Objects;
import java.util.Arrays;
import com.cloudera.api.swagger.model.ApiAtlasReplicationResult;
import com.cloudera.api.swagger.model.ApiClusterRef;
import com.cloudera.api.swagger.model.ApiCommand;
import com.cloudera.api.swagger.model.ApiCommandList;
import com.cloudera.api.swagger.model.ApiHBaseReplicationInfo;
import com.cloudera.api.swagger.model.ApiHdfsReplicationResult;
import com.cloudera.api.swagger.model.ApiHiveOnTezReplicationResult;
import com.cloudera.api.swagger.model.ApiHiveReplicationResult;
import com.cloudera.api.swagger.model.ApiHostRef;
import com.cloudera.api.swagger.model.ApiIcebergReplicationResult;
import com.cloudera.api.swagger.model.ApiOzoneReplicationResult;
import com.cloudera.api.swagger.model.ApiRangerReplicationResult;
import com.cloudera.api.swagger.model.ApiReplicationCommand;
import com.cloudera.api.swagger.model.ApiRoleRef;
import com.cloudera.api.swagger.model.ApiServiceRef;
import com.google.gson.TypeAdapter;
import com.google.gson.annotations.JsonAdapter;
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
/**
 * Information about a replication command. &lt;p/&gt; This object holds all the information a regular ApiCommand object provides, and adds specific information about the results of a replication command. &lt;p/&gt; Depending on the type of the service where the replication was run, a different result property will be populated.
 */
@Schema(description = "Information about a replication command. <p/> This object holds all the information a regular ApiCommand object provides, and adds specific information about the results of a replication command. <p/> Depending on the type of the service where the replication was run, a different result property will be populated.")
@javax.annotation.Generated(value = "io.swagger.codegen.v3.generators.java.JavaClientCodegen", date = "2026-05-19T08:29:59.033Z[Etc/UTC]")

public class ApiReplicationCommand extends ApiCommand {
  @SerializedName("hdfsResult")
  private ApiHdfsReplicationResult hdfsResult = null;

  @SerializedName("ozoneResult")
  private ApiOzoneReplicationResult ozoneResult = null;

  @SerializedName("hiveResult")
  private ApiHiveReplicationResult hiveResult = null;

  @SerializedName("hiveOnTezResult")
  private ApiHiveOnTezReplicationResult hiveOnTezResult = null;

  @SerializedName("hbaseInfo")
  private ApiHBaseReplicationInfo hbaseInfo = null;

  @SerializedName("rangerResult")
  private ApiRangerReplicationResult rangerResult = null;

  @SerializedName("icebergResult")
  private ApiIcebergReplicationResult icebergResult = null;

  @SerializedName("apiAtlasReplicationResult")
  private ApiAtlasReplicationResult apiAtlasReplicationResult = null;

  @SerializedName("apiReplicationDumpCommand")
  private ApiReplicationCommand apiReplicationDumpCommand = null;

  @SerializedName("apiReplicationFailedCommands")
  private List<ApiReplicationCommand> apiReplicationFailedCommands = null;

  @SerializedName("apiReplicationSkippedCommands")
  private List<ApiReplicationCommand> apiReplicationSkippedCommands = null;

  public ApiReplicationCommand hdfsResult(ApiHdfsReplicationResult hdfsResult) {
    this.hdfsResult = hdfsResult;
    return this;
  }

   /**
   * Get hdfsResult
   * @return hdfsResult
  **/
  @Schema(description = "")
  public ApiHdfsReplicationResult getHdfsResult() {
    return hdfsResult;
  }

  public void setHdfsResult(ApiHdfsReplicationResult hdfsResult) {
    this.hdfsResult = hdfsResult;
  }

  public ApiReplicationCommand ozoneResult(ApiOzoneReplicationResult ozoneResult) {
    this.ozoneResult = ozoneResult;
    return this;
  }

   /**
   * Get ozoneResult
   * @return ozoneResult
  **/
  @Schema(description = "")
  public ApiOzoneReplicationResult getOzoneResult() {
    return ozoneResult;
  }

  public void setOzoneResult(ApiOzoneReplicationResult ozoneResult) {
    this.ozoneResult = ozoneResult;
  }

  public ApiReplicationCommand hiveResult(ApiHiveReplicationResult hiveResult) {
    this.hiveResult = hiveResult;
    return this;
  }

   /**
   * Get hiveResult
   * @return hiveResult
  **/
  @Schema(description = "")
  public ApiHiveReplicationResult getHiveResult() {
    return hiveResult;
  }

  public void setHiveResult(ApiHiveReplicationResult hiveResult) {
    this.hiveResult = hiveResult;
  }

  public ApiReplicationCommand hiveOnTezResult(ApiHiveOnTezReplicationResult hiveOnTezResult) {
    this.hiveOnTezResult = hiveOnTezResult;
    return this;
  }

   /**
   * Get hiveOnTezResult
   * @return hiveOnTezResult
  **/
  @Schema(description = "")
  public ApiHiveOnTezReplicationResult getHiveOnTezResult() {
    return hiveOnTezResult;
  }

  public void setHiveOnTezResult(ApiHiveOnTezReplicationResult hiveOnTezResult) {
    this.hiveOnTezResult = hiveOnTezResult;
  }

  public ApiReplicationCommand hbaseInfo(ApiHBaseReplicationInfo hbaseInfo) {
    this.hbaseInfo = hbaseInfo;
    return this;
  }

   /**
   * Get hbaseInfo
   * @return hbaseInfo
  **/
  @Schema(description = "")
  public ApiHBaseReplicationInfo getHbaseInfo() {
    return hbaseInfo;
  }

  public void setHbaseInfo(ApiHBaseReplicationInfo hbaseInfo) {
    this.hbaseInfo = hbaseInfo;
  }

  public ApiReplicationCommand rangerResult(ApiRangerReplicationResult rangerResult) {
    this.rangerResult = rangerResult;
    return this;
  }

   /**
   * Get rangerResult
   * @return rangerResult
  **/
  @Schema(description = "")
  public ApiRangerReplicationResult getRangerResult() {
    return rangerResult;
  }

  public void setRangerResult(ApiRangerReplicationResult rangerResult) {
    this.rangerResult = rangerResult;
  }

  public ApiReplicationCommand icebergResult(ApiIcebergReplicationResult icebergResult) {
    this.icebergResult = icebergResult;
    return this;
  }

   /**
   * Get icebergResult
   * @return icebergResult
  **/
  @Schema(description = "")
  public ApiIcebergReplicationResult getIcebergResult() {
    return icebergResult;
  }

  public void setIcebergResult(ApiIcebergReplicationResult icebergResult) {
    this.icebergResult = icebergResult;
  }

  public ApiReplicationCommand apiAtlasReplicationResult(ApiAtlasReplicationResult apiAtlasReplicationResult) {
    this.apiAtlasReplicationResult = apiAtlasReplicationResult;
    return this;
  }

   /**
   * Get apiAtlasReplicationResult
   * @return apiAtlasReplicationResult
  **/
  @Schema(description = "")
  public ApiAtlasReplicationResult getApiAtlasReplicationResult() {
    return apiAtlasReplicationResult;
  }

  public void setApiAtlasReplicationResult(ApiAtlasReplicationResult apiAtlasReplicationResult) {
    this.apiAtlasReplicationResult = apiAtlasReplicationResult;
  }

  public ApiReplicationCommand apiReplicationDumpCommand(ApiReplicationCommand apiReplicationDumpCommand) {
    this.apiReplicationDumpCommand = apiReplicationDumpCommand;
    return this;
  }

   /**
   * Get apiReplicationDumpCommand
   * @return apiReplicationDumpCommand
  **/
  @Schema(description = "")
  public ApiReplicationCommand getApiReplicationDumpCommand() {
    return apiReplicationDumpCommand;
  }

  public void setApiReplicationDumpCommand(ApiReplicationCommand apiReplicationDumpCommand) {
    this.apiReplicationDumpCommand = apiReplicationDumpCommand;
  }

  public ApiReplicationCommand apiReplicationFailedCommands(List<ApiReplicationCommand> apiReplicationFailedCommands) {
    this.apiReplicationFailedCommands = apiReplicationFailedCommands;
    return this;
  }

  public ApiReplicationCommand addApiReplicationFailedCommandsItem(ApiReplicationCommand apiReplicationFailedCommandsItem) {
    if (this.apiReplicationFailedCommands == null) {
      this.apiReplicationFailedCommands = new ArrayList<>();
    }
    this.apiReplicationFailedCommands.add(apiReplicationFailedCommandsItem);
    return this;
  }

   /**
   * Get apiReplicationFailedCommands
   * @return apiReplicationFailedCommands
  **/
  @Schema(description = "")
  public List<ApiReplicationCommand> getApiReplicationFailedCommands() {
    return apiReplicationFailedCommands;
  }

  public void setApiReplicationFailedCommands(List<ApiReplicationCommand> apiReplicationFailedCommands) {
    this.apiReplicationFailedCommands = apiReplicationFailedCommands;
  }

  public ApiReplicationCommand apiReplicationSkippedCommands(List<ApiReplicationCommand> apiReplicationSkippedCommands) {
    this.apiReplicationSkippedCommands = apiReplicationSkippedCommands;
    return this;
  }

  public ApiReplicationCommand addApiReplicationSkippedCommandsItem(ApiReplicationCommand apiReplicationSkippedCommandsItem) {
    if (this.apiReplicationSkippedCommands == null) {
      this.apiReplicationSkippedCommands = new ArrayList<>();
    }
    this.apiReplicationSkippedCommands.add(apiReplicationSkippedCommandsItem);
    return this;
  }

   /**
   * Get apiReplicationSkippedCommands
   * @return apiReplicationSkippedCommands
  **/
  @Schema(description = "")
  public List<ApiReplicationCommand> getApiReplicationSkippedCommands() {
    return apiReplicationSkippedCommands;
  }

  public void setApiReplicationSkippedCommands(List<ApiReplicationCommand> apiReplicationSkippedCommands) {
    this.apiReplicationSkippedCommands = apiReplicationSkippedCommands;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    ApiReplicationCommand apiReplicationCommand = (ApiReplicationCommand) o;
    return Objects.equals(this.hdfsResult, apiReplicationCommand.hdfsResult) &&
        Objects.equals(this.ozoneResult, apiReplicationCommand.ozoneResult) &&
        Objects.equals(this.hiveResult, apiReplicationCommand.hiveResult) &&
        Objects.equals(this.hiveOnTezResult, apiReplicationCommand.hiveOnTezResult) &&
        Objects.equals(this.hbaseInfo, apiReplicationCommand.hbaseInfo) &&
        Objects.equals(this.rangerResult, apiReplicationCommand.rangerResult) &&
        Objects.equals(this.icebergResult, apiReplicationCommand.icebergResult) &&
        Objects.equals(this.apiAtlasReplicationResult, apiReplicationCommand.apiAtlasReplicationResult) &&
        Objects.equals(this.apiReplicationDumpCommand, apiReplicationCommand.apiReplicationDumpCommand) &&
        Objects.equals(this.apiReplicationFailedCommands, apiReplicationCommand.apiReplicationFailedCommands) &&
        Objects.equals(this.apiReplicationSkippedCommands, apiReplicationCommand.apiReplicationSkippedCommands) &&
        super.equals(o);
  }

  @Override
  public int hashCode() {
    return Objects.hash(hdfsResult, ozoneResult, hiveResult, hiveOnTezResult, hbaseInfo, rangerResult, icebergResult, apiAtlasReplicationResult, apiReplicationDumpCommand, apiReplicationFailedCommands, apiReplicationSkippedCommands, super.hashCode());
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class ApiReplicationCommand {\n");
    sb.append("    ").append(toIndentedString(super.toString())).append("\n");
    sb.append("    hdfsResult: ").append(toIndentedString(hdfsResult)).append("\n");
    sb.append("    ozoneResult: ").append(toIndentedString(ozoneResult)).append("\n");
    sb.append("    hiveResult: ").append(toIndentedString(hiveResult)).append("\n");
    sb.append("    hiveOnTezResult: ").append(toIndentedString(hiveOnTezResult)).append("\n");
    sb.append("    hbaseInfo: ").append(toIndentedString(hbaseInfo)).append("\n");
    sb.append("    rangerResult: ").append(toIndentedString(rangerResult)).append("\n");
    sb.append("    icebergResult: ").append(toIndentedString(icebergResult)).append("\n");
    sb.append("    apiAtlasReplicationResult: ").append(toIndentedString(apiAtlasReplicationResult)).append("\n");
    sb.append("    apiReplicationDumpCommand: ").append(toIndentedString(apiReplicationDumpCommand)).append("\n");
    sb.append("    apiReplicationFailedCommands: ").append(toIndentedString(apiReplicationFailedCommands)).append("\n");
    sb.append("    apiReplicationSkippedCommands: ").append(toIndentedString(apiReplicationSkippedCommands)).append("\n");
    sb.append("}");
    return sb.toString();
  }

  /**
   * Convert the given object to string with each line indented by 4 spaces
   * (except the first line).
   */
  private String toIndentedString(java.lang.Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }

}
