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

fi.metatavu.ngsi.netcdf.api.model.QueryResponse Maven / Gradle / Ivy

The newest version!
package fi.metatavu.ngsi.netcdf.api.model;

import javax.validation.constraints.*;
import javax.validation.Valid;


import io.swagger.annotations.*;
import java.util.Objects;


public class QueryResponse   {
  
  private @Valid String type = null;
  private @Valid String id = null;
  private @Valid Object temperature = null;

  /**
   * 
   **/
  public QueryResponse type(String type) {
    this.type = type;
    return this;
  }

  
  @ApiModelProperty(example = "Room", required = true, value = "")
  @NotNull
  public String getType() {
    return type;
  }
  public void setType(String type) {
    this.type = type;
  }

  /**
   * 
   **/
  public QueryResponse id(String id) {
    this.id = id;
    return this;
  }

  
  @ApiModelProperty(example = "DC_S1-D41", required = true, value = "")
  @NotNull
  public String getId() {
    return id;
  }
  public void setId(String id) {
    this.id = id;
  }

  /**
   * 
   **/
  public QueryResponse temperature(Object temperature) {
    this.temperature = temperature;
    return this;
  }

  
  @ApiModelProperty(example = "{\"value\":35.6,\"type\":\"Number\"}", required = true, value = "")
  @NotNull
  public Object getTemperature() {
    return temperature;
  }
  public void setTemperature(Object temperature) {
    this.temperature = temperature;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    QueryResponse queryResponse = (QueryResponse) o;
    return Objects.equals(type, queryResponse.type) &&
        Objects.equals(id, queryResponse.id) &&
        Objects.equals(temperature, queryResponse.temperature);
  }

  @Override
  public int hashCode() {
    return Objects.hash(type, id, temperature);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class QueryResponse {\n");
    
    sb.append("    type: ").append(toIndentedString(type)).append("\n");
    sb.append("    id: ").append(toIndentedString(id)).append("\n");
    sb.append("    temperature: ").append(toIndentedString(temperature)).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 - 2025 Weber Informatics LLC | Privacy Policy