com.seeq.model.PriorityV1 Maven / Gradle / Ivy
/*
* Seeq REST API
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 65.1.3-v202408082312
*
*
* 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.seeq.model;
import java.util.Objects;
import java.util.Arrays;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import io.swagger.v3.oas.annotations.media.Schema;
/**
* The priorities for metrics, sorted descending by level
*/
@Schema(description = "The priorities for metrics, sorted descending by level")
public class PriorityV1 {
@JsonProperty("color")
private String color = null;
@JsonProperty("level")
private Integer level = null;
@JsonProperty("name")
private String name = null;
public PriorityV1 color(String color) {
this.color = color;
return this;
}
/**
* A hex code (including pound sign) representing the color assigned to this priority
* @return color
**/
@Schema(required = true, description = "A hex code (including pound sign) representing the color assigned to this priority")
public String getColor() {
return color;
}
public void setColor(String color) {
this.color = color;
}
public PriorityV1 level(Integer level) {
this.level = level;
return this;
}
/**
* An integer representing the priority level. 0 is used for neutral, positive numbers are used for high thresholds and negative numbers for low thresholds
* @return level
**/
@Schema(required = true, description = "An integer representing the priority level. 0 is used for neutral, positive numbers are used for high thresholds and negative numbers for low thresholds")
public Integer getLevel() {
return level;
}
public void setLevel(Integer level) {
this.level = level;
}
public PriorityV1 name(String name) {
this.name = name;
return this;
}
/**
* The name of this priority
* @return name
**/
@Schema(required = true, description = "The name of this priority")
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
@Override
public boolean equals(java.lang.Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
PriorityV1 priorityV1 = (PriorityV1) o;
return Objects.equals(this.color, priorityV1.color) &&
Objects.equals(this.level, priorityV1.level) &&
Objects.equals(this.name, priorityV1.name);
}
@Override
public int hashCode() {
return Objects.hash(color, level, name);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class PriorityV1 {\n");
sb.append(" color: ").append(toIndentedString(color)).append("\n");
sb.append(" level: ").append(toIndentedString(level)).append("\n");
sb.append(" name: ").append(toIndentedString(name)).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 ");
}
}