ApiImplItem.java

  1. /*
  2.  * GovWay - A customizable API Gateway
  3.  * https://govway.org
  4.  *
  5.  * Copyright (c) 2005-2025 Link.it srl (https://link.it).
  6.  *
  7.  * This program is free software: you can redistribute it and/or modify
  8.  * it under the terms of the GNU General Public License version 3, as published by
  9.  * the Free Software Foundation.
  10.  *
  11.  * This program is distributed in the hope that it will be useful,
  12.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  14.  * GNU General Public License for more details.
  15.  *
  16.  * You should have received a copy of the GNU General Public License
  17.  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
  18.  *
  19.  */
  20. package org.openspcoop2.core.config.rs.server.model;

  21. import java.util.List;
  22. import org.openspcoop2.utils.service.beans.BaseSoggettoItem;
  23. import javax.validation.constraints.*;

  24. import io.swagger.v3.oas.annotations.media.Schema;
  25. import com.fasterxml.jackson.annotation.JsonProperty;
  26. import javax.validation.Valid;

  27. public class ApiImplItem extends BaseSoggettoItem {
  28.  
  29.   @Schema(required = true, description = "")
  30.   private String apiNome = null;
  31.  
  32.   @Schema(required = true, description = "")
  33.   private Integer apiVersione = null;
  34.  
  35.   @Schema(description = "")
  36.   private String apiReferente = null;
  37.  
  38.   @Schema(description = "")
  39.   private String apiSoapServizio = null;
  40.  
  41.   @Schema(example = "[\"PagamentiTelematici\",\"Anagrafica\"]", description = "")
  42.   private List<String> apiTags = null;
  43.  
  44.   @Schema(description = "")
  45.   private String tipoServizio = null;
  46.  
  47.   @Schema(required = true, description = "")
  48.   private String nome = null;
  49.  
  50.   @Schema(required = true, description = "")
  51.   private Integer versione = null;
  52.  
  53.   @Schema(description = "")
  54.   private TipoApiEnum apiTipo = null;
  55.  
  56.   @Schema(required = true, description = "")
  57.   private StatoApiEnum stato = null;
  58.  
  59.   @Schema(required = true, description = "")
  60.   private String statoDescrizione = null;
  61.  
  62.   @Schema(description = "")
  63.   private ApiCanale canale = null;
  64.  /**
  65.    * Get apiNome
  66.    * @return apiNome
  67.   **/
  68.   @JsonProperty("api_nome")
  69.   @NotNull
  70.   @Valid
  71.  @Pattern(regexp="^[_A-Za-z][\\-\\._A-Za-z0-9]*$") @Size(max=255)  public String getApiNome() {
  72.     return this.apiNome;
  73.   }

  74.   public void setApiNome(String apiNome) {
  75.     this.apiNome = apiNome;
  76.   }

  77.   public ApiImplItem apiNome(String apiNome) {
  78.     this.apiNome = apiNome;
  79.     return this;
  80.   }

  81.  /**
  82.    * Get apiVersione
  83.    * @return apiVersione
  84.   **/
  85.   @JsonProperty("api_versione")
  86.   @NotNull
  87.   @Valid
  88.   public Integer getApiVersione() {
  89.     return this.apiVersione;
  90.   }

  91.   public void setApiVersione(Integer apiVersione) {
  92.     this.apiVersione = apiVersione;
  93.   }

  94.   public ApiImplItem apiVersione(Integer apiVersione) {
  95.     this.apiVersione = apiVersione;
  96.     return this;
  97.   }

  98.  /**
  99.    * Get apiReferente
  100.    * @return apiReferente
  101.   **/
  102.   @JsonProperty("api_referente")
  103.   @Valid
  104.  @Pattern(regexp="^[0-9A-Za-z][\\-A-Za-z0-9]*$") @Size(max=255)  public String getApiReferente() {
  105.     return this.apiReferente;
  106.   }

  107.   public void setApiReferente(String apiReferente) {
  108.     this.apiReferente = apiReferente;
  109.   }

  110.   public ApiImplItem apiReferente(String apiReferente) {
  111.     this.apiReferente = apiReferente;
  112.     return this;
  113.   }

  114.  /**
  115.    * Get apiSoapServizio
  116.    * @return apiSoapServizio
  117.   **/
  118.   @JsonProperty("api_soap_servizio")
  119.   @Valid
  120.  @Pattern(regexp="^[_A-Za-z][\\-\\._A-Za-z0-9]*$") @Size(max=255)  public String getApiSoapServizio() {
  121.     return this.apiSoapServizio;
  122.   }

  123.   public void setApiSoapServizio(String apiSoapServizio) {
  124.     this.apiSoapServizio = apiSoapServizio;
  125.   }

  126.   public ApiImplItem apiSoapServizio(String apiSoapServizio) {
  127.     this.apiSoapServizio = apiSoapServizio;
  128.     return this;
  129.   }

  130.  /**
  131.    * Get apiTags
  132.    * @return apiTags
  133.   **/
  134.   @JsonProperty("api_tags")
  135.   @Valid
  136.   public List<String> getApiTags() {
  137.     return this.apiTags;
  138.   }

  139.   public void setApiTags(List<String> apiTags) {
  140.     this.apiTags = apiTags;
  141.   }

  142.   public ApiImplItem apiTags(List<String> apiTags) {
  143.     this.apiTags = apiTags;
  144.     return this;
  145.   }

  146.   public ApiImplItem addApiTagsItem(String apiTagsItem) {
  147.     this.apiTags.add(apiTagsItem);
  148.     return this;
  149.   }

  150.  /**
  151.    * Get tipoServizio
  152.    * @return tipoServizio
  153.   **/
  154.   @JsonProperty("tipo_servizio")
  155.   @Valid
  156.  @Pattern(regexp="^[a-z]{2,20}$") @Size(max=20)  public String getTipoServizio() {
  157.     return this.tipoServizio;
  158.   }

  159.   public void setTipoServizio(String tipoServizio) {
  160.     this.tipoServizio = tipoServizio;
  161.   }

  162.   public ApiImplItem tipoServizio(String tipoServizio) {
  163.     this.tipoServizio = tipoServizio;
  164.     return this;
  165.   }

  166.  /**
  167.    * Get nome
  168.    * @return nome
  169.   **/
  170.   @JsonProperty("nome")
  171.   @NotNull
  172.   @Valid
  173.  @Pattern(regexp="^[_A-Za-z][\\-\\._A-Za-z0-9]*$") @Size(max=255)  public String getNome() {
  174.     return this.nome;
  175.   }

  176.   public void setNome(String nome) {
  177.     this.nome = nome;
  178.   }

  179.   public ApiImplItem nome(String nome) {
  180.     this.nome = nome;
  181.     return this;
  182.   }

  183.  /**
  184.    * Get versione
  185.    * @return versione
  186.   **/
  187.   @JsonProperty("versione")
  188.   @NotNull
  189.   @Valid
  190.   public Integer getVersione() {
  191.     return this.versione;
  192.   }

  193.   public void setVersione(Integer versione) {
  194.     this.versione = versione;
  195.   }

  196.   public ApiImplItem versione(Integer versione) {
  197.     this.versione = versione;
  198.     return this;
  199.   }

  200.  /**
  201.    * Get apiTipo
  202.    * @return apiTipo
  203.   **/
  204.   @JsonProperty("api_tipo")
  205.   @Valid
  206.   public TipoApiEnum getApiTipo() {
  207.     return this.apiTipo;
  208.   }

  209.   public void setApiTipo(TipoApiEnum apiTipo) {
  210.     this.apiTipo = apiTipo;
  211.   }

  212.   public ApiImplItem apiTipo(TipoApiEnum apiTipo) {
  213.     this.apiTipo = apiTipo;
  214.     return this;
  215.   }

  216.  /**
  217.    * Get stato
  218.    * @return stato
  219.   **/
  220.   @JsonProperty("stato")
  221.   @NotNull
  222.   @Valid
  223.   public StatoApiEnum getStato() {
  224.     return this.stato;
  225.   }

  226.   public void setStato(StatoApiEnum stato) {
  227.     this.stato = stato;
  228.   }

  229.   public ApiImplItem stato(StatoApiEnum stato) {
  230.     this.stato = stato;
  231.     return this;
  232.   }

  233.  /**
  234.    * Get statoDescrizione
  235.    * @return statoDescrizione
  236.   **/
  237.   @JsonProperty("stato_descrizione")
  238.   @NotNull
  239.   @Valid
  240.   public String getStatoDescrizione() {
  241.     return this.statoDescrizione;
  242.   }

  243.   public void setStatoDescrizione(String statoDescrizione) {
  244.     this.statoDescrizione = statoDescrizione;
  245.   }

  246.   public ApiImplItem statoDescrizione(String statoDescrizione) {
  247.     this.statoDescrizione = statoDescrizione;
  248.     return this;
  249.   }

  250.  /**
  251.    * Get canale
  252.    * @return canale
  253.   **/
  254.   @JsonProperty("canale")
  255.   @Valid
  256.   public ApiCanale getCanale() {
  257.     return this.canale;
  258.   }

  259.   public void setCanale(ApiCanale canale) {
  260.     this.canale = canale;
  261.   }

  262.   public ApiImplItem canale(ApiCanale canale) {
  263.     this.canale = canale;
  264.     return this;
  265.   }


  266.   @Override
  267.   public String toString() {
  268.     StringBuilder sb = new StringBuilder();
  269.     sb.append("class ApiImplItem {\n");
  270.     sb.append("    ").append(ApiImplItem.toIndentedString(super.toString())).append("\n");
  271.     sb.append("    apiNome: ").append(ApiImplItem.toIndentedString(this.apiNome)).append("\n");
  272.     sb.append("    apiVersione: ").append(ApiImplItem.toIndentedString(this.apiVersione)).append("\n");
  273.     sb.append("    apiReferente: ").append(ApiImplItem.toIndentedString(this.apiReferente)).append("\n");
  274.     sb.append("    apiSoapServizio: ").append(ApiImplItem.toIndentedString(this.apiSoapServizio)).append("\n");
  275.     sb.append("    apiTags: ").append(ApiImplItem.toIndentedString(this.apiTags)).append("\n");
  276.     sb.append("    tipoServizio: ").append(ApiImplItem.toIndentedString(this.tipoServizio)).append("\n");
  277.     sb.append("    nome: ").append(ApiImplItem.toIndentedString(this.nome)).append("\n");
  278.     sb.append("    versione: ").append(ApiImplItem.toIndentedString(this.versione)).append("\n");
  279.     sb.append("    apiTipo: ").append(ApiImplItem.toIndentedString(this.apiTipo)).append("\n");
  280.     sb.append("    stato: ").append(ApiImplItem.toIndentedString(this.stato)).append("\n");
  281.     sb.append("    statoDescrizione: ").append(ApiImplItem.toIndentedString(this.statoDescrizione)).append("\n");
  282.     sb.append("    canale: ").append(ApiImplItem.toIndentedString(this.canale)).append("\n");
  283.     sb.append("}");
  284.     return sb.toString();
  285.   }

  286.   /**
  287.    * Convert the given object to string with each line indented by 4 spaces
  288.    * (except the first line).
  289.    */
  290.   private static String toIndentedString(java.lang.Object o) {
  291.     if (o == null) {
  292.       return "null";
  293.     }
  294.     return o.toString().replace("\n", "\n    ");
  295.   }
  296. }