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

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

  25. public class ApiModIRisorsaRest  {
  26.  
  27.   @Schema(required = true, description = "")
  28.   private ApiModIPatternInterazioneRest interazione = null;
  29.  
  30.   @Schema(required = true, description = "")
  31.   @com.fasterxml.jackson.annotation.JsonTypeInfo(use = com.fasterxml.jackson.annotation.JsonTypeInfo.Id.NAME, include = com.fasterxml.jackson.annotation.JsonTypeInfo.As.EXISTING_PROPERTY, property = "stato", visible = true )
  32.   @com.fasterxml.jackson.annotation.JsonSubTypes({
  33.     @com.fasterxml.jackson.annotation.JsonSubTypes.Type(value = ApiModISicurezzaMessaggioOperazione.class, name = "api"),
  34.     @com.fasterxml.jackson.annotation.JsonSubTypes.Type(value = ApiModISicurezzaMessaggioOperazioneRidefinito.class, name = "ridefinito")  })
  35.   private OneOfApiModIRisorsaRestSicurezzaMessaggio sicurezzaMessaggio = null;
  36.  /**
  37.    * Get interazione
  38.    * @return interazione
  39.   **/
  40.   @JsonProperty("interazione")
  41.   @NotNull
  42.   @Valid
  43.   public ApiModIPatternInterazioneRest getInterazione() {
  44.     return this.interazione;
  45.   }

  46.   public void setInterazione(ApiModIPatternInterazioneRest interazione) {
  47.     this.interazione = interazione;
  48.   }

  49.   public ApiModIRisorsaRest interazione(ApiModIPatternInterazioneRest interazione) {
  50.     this.interazione = interazione;
  51.     return this;
  52.   }

  53.  /**
  54.    * Get sicurezzaMessaggio
  55.    * @return sicurezzaMessaggio
  56.   **/
  57.   @JsonProperty("sicurezza_messaggio")
  58.   @NotNull
  59.   @Valid
  60.   public OneOfApiModIRisorsaRestSicurezzaMessaggio getSicurezzaMessaggio() {
  61.     return this.sicurezzaMessaggio;
  62.   }

  63.   public void setSicurezzaMessaggio(OneOfApiModIRisorsaRestSicurezzaMessaggio sicurezzaMessaggio) {
  64.     this.sicurezzaMessaggio = sicurezzaMessaggio;
  65.   }

  66.   public ApiModIRisorsaRest sicurezzaMessaggio(OneOfApiModIRisorsaRestSicurezzaMessaggio sicurezzaMessaggio) {
  67.     this.sicurezzaMessaggio = sicurezzaMessaggio;
  68.     return this;
  69.   }


  70.   @Override
  71.   public String toString() {
  72.     StringBuilder sb = new StringBuilder();
  73.     sb.append("class ApiModIRisorsaRest {\n");
  74.    
  75.     sb.append("    interazione: ").append(ApiModIRisorsaRest.toIndentedString(this.interazione)).append("\n");
  76.     sb.append("    sicurezzaMessaggio: ").append(ApiModIRisorsaRest.toIndentedString(this.sicurezzaMessaggio)).append("\n");
  77.     sb.append("}");
  78.     return sb.toString();
  79.   }

  80.   /**
  81.    * Convert the given object to string with each line indented by 4 spaces
  82.    * (except the first line).
  83.    */
  84.   private static String toIndentedString(java.lang.Object o) {
  85.     if (o == null) {
  86.       return "null";
  87.     }
  88.     return o.toString().replace("\n", "\n    ");
  89.   }
  90. }