APIBaseImpl.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 javax.validation.constraints.*;

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

  26. public class APIBaseImpl  {
  27.  
  28.   @Schema(required = true, description = "")
  29.   private String apiNome = null;
  30.  
  31.   @Schema(required = true, description = "")
  32.   private Integer apiVersione = null;
  33.  
  34.   @Schema(description = "")
  35.   private String apiReferente = null;
  36.  
  37.   @Schema(description = "")
  38.   private String apiSoapServizio = null;
  39.  
  40.   @Schema(example = "[\"PagamentiTelematici\",\"Anagrafica\"]", description = "")
  41.   private List<String> apiTags = null;
  42.  
  43.   @Schema(description = "")
  44.   private String tipoServizio = null;
  45.  /**
  46.    * Get apiNome
  47.    * @return apiNome
  48.   **/
  49.   @JsonProperty("api_nome")
  50.   @NotNull
  51.   @Valid
  52.  @Pattern(regexp="^[_A-Za-z][\\-\\._A-Za-z0-9]*$") @Size(max=255)  public String getApiNome() {
  53.     return this.apiNome;
  54.   }

  55.   public void setApiNome(String apiNome) {
  56.     this.apiNome = apiNome;
  57.   }

  58.   public APIBaseImpl apiNome(String apiNome) {
  59.     this.apiNome = apiNome;
  60.     return this;
  61.   }

  62.  /**
  63.    * Get apiVersione
  64.    * @return apiVersione
  65.   **/
  66.   @JsonProperty("api_versione")
  67.   @NotNull
  68.   @Valid
  69.   public Integer getApiVersione() {
  70.     return this.apiVersione;
  71.   }

  72.   public void setApiVersione(Integer apiVersione) {
  73.     this.apiVersione = apiVersione;
  74.   }

  75.   public APIBaseImpl apiVersione(Integer apiVersione) {
  76.     this.apiVersione = apiVersione;
  77.     return this;
  78.   }

  79.  /**
  80.    * Get apiReferente
  81.    * @return apiReferente
  82.   **/
  83.   @JsonProperty("api_referente")
  84.   @Valid
  85.  @Pattern(regexp="^[0-9A-Za-z][\\-A-Za-z0-9]*$") @Size(max=255)  public String getApiReferente() {
  86.     return this.apiReferente;
  87.   }

  88.   public void setApiReferente(String apiReferente) {
  89.     this.apiReferente = apiReferente;
  90.   }

  91.   public APIBaseImpl apiReferente(String apiReferente) {
  92.     this.apiReferente = apiReferente;
  93.     return this;
  94.   }

  95.  /**
  96.    * Get apiSoapServizio
  97.    * @return apiSoapServizio
  98.   **/
  99.   @JsonProperty("api_soap_servizio")
  100.   @Valid
  101.  @Pattern(regexp="^[_A-Za-z][\\-\\._A-Za-z0-9]*$") @Size(max=255)  public String getApiSoapServizio() {
  102.     return this.apiSoapServizio;
  103.   }

  104.   public void setApiSoapServizio(String apiSoapServizio) {
  105.     this.apiSoapServizio = apiSoapServizio;
  106.   }

  107.   public APIBaseImpl apiSoapServizio(String apiSoapServizio) {
  108.     this.apiSoapServizio = apiSoapServizio;
  109.     return this;
  110.   }

  111.  /**
  112.    * Get apiTags
  113.    * @return apiTags
  114.   **/
  115.   @JsonProperty("api_tags")
  116.   @Valid
  117.   public List<String> getApiTags() {
  118.     return this.apiTags;
  119.   }

  120.   public void setApiTags(List<String> apiTags) {
  121.     this.apiTags = apiTags;
  122.   }

  123.   public APIBaseImpl apiTags(List<String> apiTags) {
  124.     this.apiTags = apiTags;
  125.     return this;
  126.   }

  127.   public APIBaseImpl addApiTagsItem(String apiTagsItem) {
  128.     this.apiTags.add(apiTagsItem);
  129.     return this;
  130.   }

  131.  /**
  132.    * Get tipoServizio
  133.    * @return tipoServizio
  134.   **/
  135.   @JsonProperty("tipo_servizio")
  136.   @Valid
  137.  @Pattern(regexp="^[a-z]{2,20}$") @Size(max=20)  public String getTipoServizio() {
  138.     return this.tipoServizio;
  139.   }

  140.   public void setTipoServizio(String tipoServizio) {
  141.     this.tipoServizio = tipoServizio;
  142.   }

  143.   public APIBaseImpl tipoServizio(String tipoServizio) {
  144.     this.tipoServizio = tipoServizio;
  145.     return this;
  146.   }


  147.   @Override
  148.   public String toString() {
  149.     StringBuilder sb = new StringBuilder();
  150.     sb.append("class APIBaseImpl {\n");
  151.    
  152.     sb.append("    apiNome: ").append(APIBaseImpl.toIndentedString(this.apiNome)).append("\n");
  153.     sb.append("    apiVersione: ").append(APIBaseImpl.toIndentedString(this.apiVersione)).append("\n");
  154.     sb.append("    apiReferente: ").append(APIBaseImpl.toIndentedString(this.apiReferente)).append("\n");
  155.     sb.append("    apiSoapServizio: ").append(APIBaseImpl.toIndentedString(this.apiSoapServizio)).append("\n");
  156.     sb.append("    apiTags: ").append(APIBaseImpl.toIndentedString(this.apiTags)).append("\n");
  157.     sb.append("    tipoServizio: ").append(APIBaseImpl.toIndentedString(this.tipoServizio)).append("\n");
  158.     sb.append("}");
  159.     return sb.toString();
  160.   }

  161.   /**
  162.    * Convert the given object to string with each line indented by 4 spaces
  163.    * (except the first line).
  164.    */
  165.   private static String toIndentedString(java.lang.Object o) {
  166.     if (o == null) {
  167.       return "null";
  168.     }
  169.     return o.toString().replace("\n", "\n    ");
  170.   }
  171. }