/*
 * Kubernetes
 * No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
 *
 * OpenAPI spec version: v1.10.4
 * 
 *
 * 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 io.kubernetes.client.models;

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.kubernetes.client.models.V1alpha1VolumeAttachmentSource;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.IOException;

/**
 * VolumeAttachmentSpec is the specification of a VolumeAttachment request.
 */
@ApiModel(description = "VolumeAttachmentSpec is the specification of a VolumeAttachment request.")

public class V1alpha1VolumeAttachmentSpec {
  @SerializedName("attacher")
  private String attacher = null;

  @SerializedName("nodeName")
  private String nodeName = null;

  @SerializedName("source")
  private V1alpha1VolumeAttachmentSource source = null;

  public V1alpha1VolumeAttachmentSpec attacher(String attacher) {
    this.attacher = attacher;
    return this;
  }

   /**
   * Attacher indicates the name of the volume driver that MUST handle this request. This is the name returned by GetPluginName().
   * @return attacher
  **/
  @ApiModelProperty(required = true, value = "Attacher indicates the name of the volume driver that MUST handle this request. This is the name returned by GetPluginName().")
  public String getAttacher() {
    return attacher;
  }

  public void setAttacher(String attacher) {
    this.attacher = attacher;
  }

  public V1alpha1VolumeAttachmentSpec nodeName(String nodeName) {
    this.nodeName = nodeName;
    return this;
  }

   /**
   * The node that the volume should be attached to.
   * @return nodeName
  **/
  @ApiModelProperty(required = true, value = "The node that the volume should be attached to.")
  public String getNodeName() {
    return nodeName;
  }

  public void setNodeName(String nodeName) {
    this.nodeName = nodeName;
  }

  public V1alpha1VolumeAttachmentSpec source(V1alpha1VolumeAttachmentSource source) {
    this.source = source;
    return this;
  }

   /**
   * Source represents the volume that should be attached.
   * @return source
  **/
  @ApiModelProperty(required = true, value = "Source represents the volume that should be attached.")
  public V1alpha1VolumeAttachmentSource getSource() {
    return source;
  }

  public void setSource(V1alpha1VolumeAttachmentSource source) {
    this.source = source;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    V1alpha1VolumeAttachmentSpec v1alpha1VolumeAttachmentSpec = (V1alpha1VolumeAttachmentSpec) o;
    return Objects.equals(this.attacher, v1alpha1VolumeAttachmentSpec.attacher) &&
        Objects.equals(this.nodeName, v1alpha1VolumeAttachmentSpec.nodeName) &&
        Objects.equals(this.source, v1alpha1VolumeAttachmentSpec.source);
  }

  @Override
  public int hashCode() {
    return Objects.hash(attacher, nodeName, source);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class V1alpha1VolumeAttachmentSpec {\n");
    
    sb.append("    attacher: ").append(toIndentedString(attacher)).append("\n");
    sb.append("    nodeName: ").append(toIndentedString(nodeName)).append("\n");
    sb.append("    source: ").append(toIndentedString(source)).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    ");
  }

}

