Compatibility.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.mvc.properties;

  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 java.io.Serializable;
  28. import java.util.ArrayList;
  29. import java.util.List;


  30. /** <p>Java class for compatibility complex type.
  31.  *
  32.  * <p>The following schema fragment specifies the expected content contained within this class.
  33.  *
  34.  * <pre>
  35.  * &lt;complexType name="compatibility"&gt;
  36.  *      &lt;sequence&gt;
  37.  *          &lt;element name="tags" type="{http://www.openspcoop2.org/core/mvc/properties}tags" minOccurs="1" maxOccurs="unbounded"/&gt;
  38.  *      &lt;/sequence&gt;
  39.  *      &lt;attribute name="and" type="{http://www.w3.org/2001/XMLSchema}boolean" use="optional" default="true"/&gt;
  40.  *      &lt;attribute name="not" type="{http://www.w3.org/2001/XMLSchema}boolean" use="optional" default="false"/&gt;
  41.  * &lt;/complexType&gt;
  42.  * </pre>
  43.  *
  44.  * @version $Rev$, $Date$
  45.  *
  46.  * @author Poli Andrea (poli@link.it)
  47.  * @author $Author$
  48.  * */

  49. @XmlAccessorType(XmlAccessType.FIELD)
  50. @XmlType(name = "compatibility",
  51.   propOrder = {
  52.     "tags"
  53.   }
  54. )

  55. @XmlRootElement(name = "compatibility")

  56. public class Compatibility extends org.openspcoop2.utils.beans.BaseBean implements Serializable , Cloneable {
  57.   public Compatibility() {
  58.     super();
  59.   }

  60.   public void addTags(Tags tags) {
  61.     this.tags.add(tags);
  62.   }

  63.   public Tags getTags(int index) {
  64.     return this.tags.get( index );
  65.   }

  66.   public Tags removeTags(int index) {
  67.     return this.tags.remove( index );
  68.   }

  69.   public List<Tags> getTagsList() {
  70.     return this.tags;
  71.   }

  72.   public void setTagsList(List<Tags> tags) {
  73.     this.tags=tags;
  74.   }

  75.   public int sizeTagsList() {
  76.     return this.tags.size();
  77.   }

  78.   public boolean isAnd() {
  79.     return this.and;
  80.   }

  81.   public boolean getAnd() {
  82.     return this.and;
  83.   }

  84.   public void setAnd(boolean and) {
  85.     this.and = and;
  86.   }

  87.   public boolean isNot() {
  88.     return this.not;
  89.   }

  90.   public boolean getNot() {
  91.     return this.not;
  92.   }

  93.   public void setNot(boolean not) {
  94.     this.not = not;
  95.   }

  96.   private static final long serialVersionUID = 1L;



  97.   @XmlElement(name="tags",required=true,nillable=false)
  98.   private List<Tags> tags = new ArrayList<>();

  99.   /**
  100.    * Use method getTagsList
  101.    * @return List&lt;Tags&gt;
  102.   */
  103.   public List<Tags> getTags() {
  104.     return this.getTagsList();
  105.   }

  106.   /**
  107.    * Use method setTagsList
  108.    * @param tags List&lt;Tags&gt;
  109.   */
  110.   public void setTags(List<Tags> tags) {
  111.     this.setTagsList(tags);
  112.   }

  113.   /**
  114.    * Use method sizeTagsList
  115.    * @return lunghezza della lista
  116.   */
  117.   public int sizeTags() {
  118.     return this.sizeTagsList();
  119.   }

  120.   @javax.xml.bind.annotation.XmlSchemaType(name="boolean")
  121.   @XmlAttribute(name="and",required=false)
  122.   protected boolean and = true;

  123.   @javax.xml.bind.annotation.XmlSchemaType(name="boolean")
  124.   @XmlAttribute(name="not",required=false)
  125.   protected boolean not = false;

  126. }