ResponseCachingConfigurazioneHashGenerator.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;

  21. import javax.xml.bind.annotation.XmlAccessType;
  22. import javax.xml.bind.annotation.XmlAccessorType;
  23. import javax.xml.bind.annotation.XmlAttribute;
  24. import javax.xml.bind.annotation.XmlElement;
  25. import javax.xml.bind.annotation.XmlRootElement;
  26. import javax.xml.bind.annotation.XmlType;
  27. import org.openspcoop2.core.config.constants.StatoFunzionalita;
  28. import org.openspcoop2.core.config.constants.StatoFunzionalitaCacheDigestQueryParameter;
  29. import java.io.Serializable;
  30. import java.util.ArrayList;
  31. import java.util.List;


  32. /** <p>Java class for response-caching-configurazione-hash-generator complex type.
  33.  *
  34.  * <p>The following schema fragment specifies the expected content contained within this class.
  35.  *
  36.  * <pre>
  37.  * &lt;complexType name="response-caching-configurazione-hash-generator"&gt;
  38.  *      &lt;sequence&gt;
  39.  *          &lt;element name="header" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0" maxOccurs="unbounded"/&gt;
  40.  *          &lt;element name="query-parameter" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0" maxOccurs="unbounded"/&gt;
  41.  *      &lt;/sequence&gt;
  42.  *      &lt;attribute name="request-uri" type="{http://www.openspcoop2.org/core/config}StatoFunzionalita" use="optional" default="abilitato"/&gt;
  43.  *      &lt;attribute name="query-parameters" type="{http://www.openspcoop2.org/core/config}StatoFunzionalitaCacheDigestQueryParameter" use="optional" default="abilitato"/&gt;
  44.  *      &lt;attribute name="headers" type="{http://www.openspcoop2.org/core/config}StatoFunzionalita" use="optional" default="disabilitato"/&gt;
  45.  *      &lt;attribute name="payload" type="{http://www.openspcoop2.org/core/config}StatoFunzionalita" use="optional" default="abilitato"/&gt;
  46.  * &lt;/complexType&gt;
  47.  * </pre>
  48.  *
  49.  * @version $Rev$, $Date$
  50.  *
  51.  * @author Poli Andrea (poli@link.it)
  52.  * @author $Author$
  53.  * */

  54. @XmlAccessorType(XmlAccessType.FIELD)
  55. @XmlType(name = "response-caching-configurazione-hash-generator",
  56.   propOrder = {
  57.     "header",
  58.     "queryParameter"
  59.   }
  60. )

  61. @XmlRootElement(name = "response-caching-configurazione-hash-generator")

  62. public class ResponseCachingConfigurazioneHashGenerator extends org.openspcoop2.utils.beans.BaseBeanWithId implements Serializable , Cloneable {
  63.   public ResponseCachingConfigurazioneHashGenerator() {
  64.     super();
  65.   }

  66.   public void addHeader(java.lang.String header) {
  67.     this.header.add(header);
  68.   }

  69.   public java.lang.String getHeader(int index) {
  70.     return this.header.get( index );
  71.   }

  72.   public java.lang.String removeHeader(int index) {
  73.     return this.header.remove( index );
  74.   }

  75.   public List<java.lang.String> getHeaderList() {
  76.     return this.header;
  77.   }

  78.   public void setHeaderList(List<java.lang.String> header) {
  79.     this.header=header;
  80.   }

  81.   public int sizeHeaderList() {
  82.     return this.header.size();
  83.   }

  84.   public void addQueryParameter(java.lang.String queryParameter) {
  85.     this.queryParameter.add(queryParameter);
  86.   }

  87.   public java.lang.String getQueryParameter(int index) {
  88.     return this.queryParameter.get( index );
  89.   }

  90.   public java.lang.String removeQueryParameter(int index) {
  91.     return this.queryParameter.remove( index );
  92.   }

  93.   public List<java.lang.String> getQueryParameterList() {
  94.     return this.queryParameter;
  95.   }

  96.   public void setQueryParameterList(List<java.lang.String> queryParameter) {
  97.     this.queryParameter=queryParameter;
  98.   }

  99.   public int sizeQueryParameterList() {
  100.     return this.queryParameter.size();
  101.   }

  102.   public void setRequestUriRawEnumValue(String value) {
  103.     this.requestUri = (StatoFunzionalita) StatoFunzionalita.toEnumConstantFromString(value);
  104.   }

  105.   public String getRequestUriRawEnumValue() {
  106.     if(this.requestUri == null){
  107.         return null;
  108.     }else{
  109.         return this.requestUri.toString();
  110.     }
  111.   }

  112.   public org.openspcoop2.core.config.constants.StatoFunzionalita getRequestUri() {
  113.     return this.requestUri;
  114.   }

  115.   public void setRequestUri(org.openspcoop2.core.config.constants.StatoFunzionalita requestUri) {
  116.     this.requestUri = requestUri;
  117.   }

  118.   public void setQueryParametersRawEnumValue(String value) {
  119.     this.queryParameters = (StatoFunzionalitaCacheDigestQueryParameter) StatoFunzionalitaCacheDigestQueryParameter.toEnumConstantFromString(value);
  120.   }

  121.   public String getQueryParametersRawEnumValue() {
  122.     if(this.queryParameters == null){
  123.         return null;
  124.     }else{
  125.         return this.queryParameters.toString();
  126.     }
  127.   }

  128.   public org.openspcoop2.core.config.constants.StatoFunzionalitaCacheDigestQueryParameter getQueryParameters() {
  129.     return this.queryParameters;
  130.   }

  131.   public void setQueryParameters(org.openspcoop2.core.config.constants.StatoFunzionalitaCacheDigestQueryParameter queryParameters) {
  132.     this.queryParameters = queryParameters;
  133.   }

  134.   public void setHeadersRawEnumValue(String value) {
  135.     this.headers = (StatoFunzionalita) StatoFunzionalita.toEnumConstantFromString(value);
  136.   }

  137.   public String getHeadersRawEnumValue() {
  138.     if(this.headers == null){
  139.         return null;
  140.     }else{
  141.         return this.headers.toString();
  142.     }
  143.   }

  144.   public org.openspcoop2.core.config.constants.StatoFunzionalita getHeaders() {
  145.     return this.headers;
  146.   }

  147.   public void setHeaders(org.openspcoop2.core.config.constants.StatoFunzionalita headers) {
  148.     this.headers = headers;
  149.   }

  150.   public void setPayloadRawEnumValue(String value) {
  151.     this.payload = (StatoFunzionalita) StatoFunzionalita.toEnumConstantFromString(value);
  152.   }

  153.   public String getPayloadRawEnumValue() {
  154.     if(this.payload == null){
  155.         return null;
  156.     }else{
  157.         return this.payload.toString();
  158.     }
  159.   }

  160.   public org.openspcoop2.core.config.constants.StatoFunzionalita getPayload() {
  161.     return this.payload;
  162.   }

  163.   public void setPayload(org.openspcoop2.core.config.constants.StatoFunzionalita payload) {
  164.     this.payload = payload;
  165.   }

  166.   private static final long serialVersionUID = 1L;



  167.   @javax.xml.bind.annotation.XmlSchemaType(name="string")
  168.   @XmlElement(name="header",required=true,nillable=false)
  169.   private List<java.lang.String> header = new ArrayList<>();

  170.   /**
  171.    * Use method getHeaderList
  172.    * @return List&lt;java.lang.String&gt;
  173.   */
  174.   public List<java.lang.String> getHeader() {
  175.     return this.getHeaderList();
  176.   }

  177.   /**
  178.    * Use method setHeaderList
  179.    * @param header List&lt;java.lang.String&gt;
  180.   */
  181.   public void setHeader(List<java.lang.String> header) {
  182.     this.setHeaderList(header);
  183.   }

  184.   /**
  185.    * Use method sizeHeaderList
  186.    * @return lunghezza della lista
  187.   */
  188.   public int sizeHeader() {
  189.     return this.sizeHeaderList();
  190.   }

  191.   @javax.xml.bind.annotation.XmlSchemaType(name="string")
  192.   @XmlElement(name="query-parameter",required=true,nillable=false)
  193.   private List<java.lang.String> queryParameter = new ArrayList<>();

  194.   /**
  195.    * Use method getQueryParameterList
  196.    * @return List&lt;java.lang.String&gt;
  197.   */
  198.   public List<java.lang.String> getQueryParameter() {
  199.     return this.getQueryParameterList();
  200.   }

  201.   /**
  202.    * Use method setQueryParameterList
  203.    * @param queryParameter List&lt;java.lang.String&gt;
  204.   */
  205.   public void setQueryParameter(List<java.lang.String> queryParameter) {
  206.     this.setQueryParameterList(queryParameter);
  207.   }

  208.   /**
  209.    * Use method sizeQueryParameterList
  210.    * @return lunghezza della lista
  211.   */
  212.   public int sizeQueryParameter() {
  213.     return this.sizeQueryParameterList();
  214.   }

  215.   @javax.xml.bind.annotation.XmlTransient
  216.   protected java.lang.String requestUriRawEnumValue;

  217.   @XmlAttribute(name="request-uri",required=false)
  218.   protected StatoFunzionalita requestUri = (StatoFunzionalita) StatoFunzionalita.toEnumConstantFromString("abilitato");

  219.   @javax.xml.bind.annotation.XmlTransient
  220.   protected java.lang.String queryParametersRawEnumValue;

  221.   @XmlAttribute(name="query-parameters",required=false)
  222.   protected StatoFunzionalitaCacheDigestQueryParameter queryParameters = (StatoFunzionalitaCacheDigestQueryParameter) StatoFunzionalitaCacheDigestQueryParameter.toEnumConstantFromString("abilitato");

  223.   @javax.xml.bind.annotation.XmlTransient
  224.   protected java.lang.String headersRawEnumValue;

  225.   @XmlAttribute(name="headers",required=false)
  226.   protected StatoFunzionalita headers = (StatoFunzionalita) StatoFunzionalita.toEnumConstantFromString("disabilitato");

  227.   @javax.xml.bind.annotation.XmlTransient
  228.   protected java.lang.String payloadRawEnumValue;

  229.   @XmlAttribute(name="payload",required=false)
  230.   protected StatoFunzionalita payload = (StatoFunzionalita) StatoFunzionalita.toEnumConstantFromString("abilitato");

  231. }