All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.mypurecloud.sdk.model.Change Maven / Gradle / Ivy

The newest version!
package com.mypurecloud.sdk.model;

import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import java.util.Objects;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.mypurecloud.sdk.model.AuditEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.ArrayList;
import java.util.List;

import java.io.Serializable;
/**
 * Change
 */

public class Change  implements Serializable {
  
  private AuditEntity entity = null;
  private String property = null;
  private List oldValues = new ArrayList();
  private List newValues = new ArrayList();

  
  /**
   **/
  public Change entity(AuditEntity entity) {
    this.entity = entity;
    return this;
  }
  
  @ApiModelProperty(example = "null", value = "")
  @JsonProperty("entity")
  public AuditEntity getEntity() {
    return entity;
  }
  public void setEntity(AuditEntity entity) {
    this.entity = entity;
  }


  /**
   * The property that was changed
   **/
  public Change property(String property) {
    this.property = property;
    return this;
  }
  
  @ApiModelProperty(example = "null", value = "The property that was changed")
  @JsonProperty("property")
  public String getProperty() {
    return property;
  }
  public void setProperty(String property) {
    this.property = property;
  }


  /**
   * The old values which were modified and/or removed by this action.
   **/
  public Change oldValues(List oldValues) {
    this.oldValues = oldValues;
    return this;
  }
  
  @ApiModelProperty(example = "null", value = "The old values which were modified and/or removed by this action.")
  @JsonProperty("oldValues")
  public List getOldValues() {
    return oldValues;
  }
  public void setOldValues(List oldValues) {
    this.oldValues = oldValues;
  }


  /**
   * The new values which were modified and/or added by this action.
   **/
  public Change newValues(List newValues) {
    this.newValues = newValues;
    return this;
  }
  
  @ApiModelProperty(example = "null", value = "The new values which were modified and/or added by this action.")
  @JsonProperty("newValues")
  public List getNewValues() {
    return newValues;
  }
  public void setNewValues(List newValues) {
    this.newValues = newValues;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    Change change = (Change) o;
    return Objects.equals(this.entity, change.entity) &&
        Objects.equals(this.property, change.property) &&
        Objects.equals(this.oldValues, change.oldValues) &&
        Objects.equals(this.newValues, change.newValues);
  }

  @Override
  public int hashCode() {
    return Objects.hash(entity, property, oldValues, newValues);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class Change {\n");
    
    sb.append("    entity: ").append(toIndentedString(entity)).append("\n");
    sb.append("    property: ").append(toIndentedString(property)).append("\n");
    sb.append("    oldValues: ").append(toIndentedString(oldValues)).append("\n");
    sb.append("    newValues: ").append(toIndentedString(newValues)).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    ");
  }
}





© 2015 - 2024 Weber Informatics LLC | Privacy Policy