/*
 * Azure Blockchain Workbench REST API
 * The Azure Blockchain Workbench REST API is a Workbench extensibility point, which allows developers to create and manage blockchain applications, manage users and organizations within a consortium, integrate blockchain applications into services and platforms, perform transactions on a blockchain, and retrieve transactional and contract data from a blockchain.
 *
 * OpenAPI spec version: v1
 * 
 *
 * 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.swagger.client.model;

import java.util.Objects;
import java.util.Arrays;
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 io.swagger.client.model.WorkflowStateTransition;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;

/**
 * WorkflowState
 */

public class WorkflowState {
  @SerializedName("id")
  private Integer id = null;

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

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

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

  @SerializedName("percentComplete")
  private Integer percentComplete = null;

  @SerializedName("value")
  private Integer value = null;

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

  @SerializedName("workflowStateTransitions")
  private List<WorkflowStateTransition> workflowStateTransitions = null;

  public WorkflowState id(Integer id) {
    this.id = id;
    return this;
  }

   /**
   * Get id
   * @return id
  **/
  @ApiModelProperty(value = "")
  public Integer getId() {
    return id;
  }

  public void setId(Integer id) {
    this.id = id;
  }

  public WorkflowState name(String name) {
    this.name = name;
    return this;
  }

   /**
   * Get name
   * @return name
  **/
  @ApiModelProperty(value = "")
  public String getName() {
    return name;
  }

  public void setName(String name) {
    this.name = name;
  }

  public WorkflowState description(String description) {
    this.description = description;
    return this;
  }

   /**
   * Get description
   * @return description
  **/
  @ApiModelProperty(value = "")
  public String getDescription() {
    return description;
  }

  public void setDescription(String description) {
    this.description = description;
  }

  public WorkflowState displayName(String displayName) {
    this.displayName = displayName;
    return this;
  }

   /**
   * Get displayName
   * @return displayName
  **/
  @ApiModelProperty(value = "")
  public String getDisplayName() {
    return displayName;
  }

  public void setDisplayName(String displayName) {
    this.displayName = displayName;
  }

  public WorkflowState percentComplete(Integer percentComplete) {
    this.percentComplete = percentComplete;
    return this;
  }

   /**
   * Get percentComplete
   * @return percentComplete
  **/
  @ApiModelProperty(value = "")
  public Integer getPercentComplete() {
    return percentComplete;
  }

  public void setPercentComplete(Integer percentComplete) {
    this.percentComplete = percentComplete;
  }

  public WorkflowState value(Integer value) {
    this.value = value;
    return this;
  }

   /**
   * Get value
   * @return value
  **/
  @ApiModelProperty(value = "")
  public Integer getValue() {
    return value;
  }

  public void setValue(Integer value) {
    this.value = value;
  }

  public WorkflowState style(String style) {
    this.style = style;
    return this;
  }

   /**
   * Get style
   * @return style
  **/
  @ApiModelProperty(value = "")
  public String getStyle() {
    return style;
  }

  public void setStyle(String style) {
    this.style = style;
  }

  public WorkflowState workflowStateTransitions(List<WorkflowStateTransition> workflowStateTransitions) {
    this.workflowStateTransitions = workflowStateTransitions;
    return this;
  }

  public WorkflowState addWorkflowStateTransitionsItem(WorkflowStateTransition workflowStateTransitionsItem) {
    if (this.workflowStateTransitions == null) {
      this.workflowStateTransitions = new ArrayList<WorkflowStateTransition>();
    }
    this.workflowStateTransitions.add(workflowStateTransitionsItem);
    return this;
  }

   /**
   * Get workflowStateTransitions
   * @return workflowStateTransitions
  **/
  @ApiModelProperty(value = "")
  public List<WorkflowStateTransition> getWorkflowStateTransitions() {
    return workflowStateTransitions;
  }

  public void setWorkflowStateTransitions(List<WorkflowStateTransition> workflowStateTransitions) {
    this.workflowStateTransitions = workflowStateTransitions;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    WorkflowState workflowState = (WorkflowState) o;
    return Objects.equals(this.id, workflowState.id) &&
        Objects.equals(this.name, workflowState.name) &&
        Objects.equals(this.description, workflowState.description) &&
        Objects.equals(this.displayName, workflowState.displayName) &&
        Objects.equals(this.percentComplete, workflowState.percentComplete) &&
        Objects.equals(this.value, workflowState.value) &&
        Objects.equals(this.style, workflowState.style) &&
        Objects.equals(this.workflowStateTransitions, workflowState.workflowStateTransitions);
  }

  @Override
  public int hashCode() {
    return Objects.hash(id, name, description, displayName, percentComplete, value, style, workflowStateTransitions);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class WorkflowState {\n");
    
    sb.append("    id: ").append(toIndentedString(id)).append("\n");
    sb.append("    name: ").append(toIndentedString(name)).append("\n");
    sb.append("    description: ").append(toIndentedString(description)).append("\n");
    sb.append("    displayName: ").append(toIndentedString(displayName)).append("\n");
    sb.append("    percentComplete: ").append(toIndentedString(percentComplete)).append("\n");
    sb.append("    value: ").append(toIndentedString(value)).append("\n");
    sb.append("    style: ").append(toIndentedString(style)).append("\n");
    sb.append("    workflowStateTransitions: ").append(toIndentedString(workflowStateTransitions)).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    ");
  }

}

