/*
 * Cloudera Manager API
 * <h1>Cloudera Manager API v50</h1>       <p>Introduced in Cloudera Manager 7.8.1</p>       <p><a href=\"http://www.cloudera.com/documentation.html\">Cloudera Product Documentation</a></p>
 *
 * OpenAPI spec version: 7.8.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 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.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.IOException;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * 
 */
@ApiModel(description = "")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2022-11-17T16:38:34.097Z")
public class ApiAddSBNNToNSArguments {
  @SerializedName("nameServiceName")
  private String nameServiceName = null;

  @SerializedName("newNNHostIds")
  private List<String> newNNHostIds = null;

  @SerializedName("newNNDataDirs")
  private Map<String, String> newNNDataDirs = null;

  @SerializedName("clearDataDirs")
  private Boolean clearDataDirs = null;

  @SerializedName("restartCluster")
  private Boolean restartCluster = null;

  public ApiAddSBNNToNSArguments nameServiceName(String nameServiceName) {
    this.nameServiceName = nameServiceName;
    return this;
  }

   /**
   * The name of the NameService to which the new NameNode(s) should be added.
   * @return nameServiceName
  **/
  @ApiModelProperty(value = "The name of the NameService to which the new NameNode(s) should be added.")
  public String getNameServiceName() {
    return nameServiceName;
  }

  public void setNameServiceName(String nameServiceName) {
    this.nameServiceName = nameServiceName;
  }

  public ApiAddSBNNToNSArguments newNNHostIds(List<String> newNNHostIds) {
    this.newNNHostIds = newNNHostIds;
    return this;
  }

  public ApiAddSBNNToNSArguments addNewNNHostIdsItem(String newNNHostIdsItem) {
    if (this.newNNHostIds == null) {
      this.newNNHostIds = new ArrayList<String>();
    }
    this.newNNHostIds.add(newNNHostIdsItem);
    return this;
  }

   /**
   * List of host ids to which new NameNode(s) should be added.
   * @return newNNHostIds
  **/
  @ApiModelProperty(value = "List of host ids to which new NameNode(s) should be added.")
  public List<String> getNewNNHostIds() {
    return newNNHostIds;
  }

  public void setNewNNHostIds(List<String> newNNHostIds) {
    this.newNNHostIds = newNNHostIds;
  }

  public ApiAddSBNNToNSArguments newNNDataDirs(Map<String, String> newNNDataDirs) {
    this.newNNDataDirs = newNNDataDirs;
    return this;
  }

  public ApiAddSBNNToNSArguments putNewNNDataDirsItem(String key, String newNNDataDirsItem) {
    if (this.newNNDataDirs == null) {
      this.newNNDataDirs = new HashMap<String, String>();
    }
    this.newNNDataDirs.put(key, newNNDataDirsItem);
    return this;
  }

   /**
   * Mapping of NameNode Data Directories list to host id(s), key is the host id, the value is a comma separated list of directories to be set as NameNode Data Directories for the new NameNode(s).
   * @return newNNDataDirs
  **/
  @ApiModelProperty(value = "Mapping of NameNode Data Directories list to host id(s), key is the host id, the value is a comma separated list of directories to be set as NameNode Data Directories for the new NameNode(s).")
  public Map<String, String> getNewNNDataDirs() {
    return newNNDataDirs;
  }

  public void setNewNNDataDirs(Map<String, String> newNNDataDirs) {
    this.newNNDataDirs = newNNDataDirs;
  }

  public ApiAddSBNNToNSArguments clearDataDirs(Boolean clearDataDirs) {
    this.clearDataDirs = clearDataDirs;
    return this;
  }

   /**
   * Specifies whether the NameNode Data Directories configured should be cleared as a first step, or the command should fail if the directories specified are not empty.
   * @return clearDataDirs
  **/
  @ApiModelProperty(value = "Specifies whether the NameNode Data Directories configured should be cleared as a first step, or the command should fail if the directories specified are not empty.")
  public Boolean getClearDataDirs() {
    return clearDataDirs;
  }

  public void setClearDataDirs(Boolean clearDataDirs) {
    this.clearDataDirs = clearDataDirs;
  }

  public ApiAddSBNNToNSArguments restartCluster(Boolean restartCluster) {
    this.restartCluster = restartCluster;
    return this;
  }

   /**
   * Specifies whether the HDFS dependent services of the cluster should be restarted after the changes are applied, to reconfigure dependent services
   * @return restartCluster
  **/
  @ApiModelProperty(value = "Specifies whether the HDFS dependent services of the cluster should be restarted after the changes are applied, to reconfigure dependent services")
  public Boolean getRestartCluster() {
    return restartCluster;
  }

  public void setRestartCluster(Boolean restartCluster) {
    this.restartCluster = restartCluster;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    ApiAddSBNNToNSArguments apiAddSBNNToNSArguments = (ApiAddSBNNToNSArguments) o;
    return Objects.equals(this.nameServiceName, apiAddSBNNToNSArguments.nameServiceName) &&
        Objects.equals(this.newNNHostIds, apiAddSBNNToNSArguments.newNNHostIds) &&
        Objects.equals(this.newNNDataDirs, apiAddSBNNToNSArguments.newNNDataDirs) &&
        Objects.equals(this.clearDataDirs, apiAddSBNNToNSArguments.clearDataDirs) &&
        Objects.equals(this.restartCluster, apiAddSBNNToNSArguments.restartCluster);
  }

  @Override
  public int hashCode() {
    return Objects.hash(nameServiceName, newNNHostIds, newNNDataDirs, clearDataDirs, restartCluster);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class ApiAddSBNNToNSArguments {\n");
    
    sb.append("    nameServiceName: ").append(toIndentedString(nameServiceName)).append("\n");
    sb.append("    newNNHostIds: ").append(toIndentedString(newNNHostIds)).append("\n");
    sb.append("    newNNDataDirs: ").append(toIndentedString(newNNDataDirs)).append("\n");
    sb.append("    clearDataDirs: ").append(toIndentedString(clearDataDirs)).append("\n");
    sb.append("    restartCluster: ").append(toIndentedString(restartCluster)).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    ");
  }
  
}

