MappingRicostruzioneDiagnostici.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.pdd.logger.diagnostica;

  21. import java.io.Serializable;
  22. import java.util.List;

  23. import org.openspcoop2.generic_project.beans.IEnumeration;

  24. import org.openspcoop2.pdd.logger.record.InfoDato;
  25. import org.openspcoop2.utils.UtilsRuntimeException;

  26. /**    
  27.  * Enumeration dell'elemento TipoSeverita xsd (tipo:int)
  28.  *
  29.  * @author Poli Andrea (poli@link.it)
  30.  * @author $Author$
  31.  * @version $Rev$, $Date$
  32.  */
  33. public enum MappingRicostruzioneDiagnostici implements IEnumeration , Serializable , Cloneable {

  34.    
  35.     DIAGNOSTICI_EMESSI (CostantiMappingDiagnostici.DIAGNOSTICI_EMESSI),
  36.    
  37.     DIAGNOSTICI_EMISSIONE_FIRST_DATE (CostantiMappingDiagnostici.DIAGNOSTICI_EMISSIONE_FIRST_DATE),
  38.    
  39.     TIPO_AUTORIZZAZIONE (CostantiMappingDiagnostici.TIPO_AUTORIZZAZIONE),
  40.    
  41.     CODICE_TRASPORTO_RICHIESTA (CostantiMappingDiagnostici.CODICE_TRASPORTO_RICHIESTA),
  42.    
  43.     CODICE_TRASPORTO_RISPOSTA (CostantiMappingDiagnostici.CODICE_TRASPORTO_RISPOSTA),
  44.    
  45.     TIPO_CONNETTORE (CostantiMappingDiagnostici.TIPO_CONNETTORE),
  46.    
  47.     MAX_THREADS_THRESHOLD (CostantiMappingDiagnostici.MAX_THREADS_THRESHOLD),
  48.    
  49.     CONTROLLO_TRAFFICO_THRESHOLD (CostantiMappingDiagnostici.CONTROLLO_TRAFFICO_THRESHOLD),
  50.    
  51.     ACTIVE_THREADS (CostantiMappingDiagnostici.ACTIVE_THREADS),
  52.    
  53.     NUMERO_POLICY_CONFIGURATE (CostantiMappingDiagnostici.NUMERO_POLICY_CONFIGURATE),
  54.    
  55.     NUMERO_POLICY_DISABILITATE (CostantiMappingDiagnostici.NUMERO_POLICY_DISABILITATE),
  56.    
  57.     NUMERO_POLICY_FILTRATE (CostantiMappingDiagnostici.NUMERO_POLICY_FILTRATE),
  58.    
  59.     NUMERO_POLICY_NON_APPLICATE (CostantiMappingDiagnostici.NUMERO_POLICY_NON_APPLICATE),
  60.    
  61.     NUMERO_POLICY_RISPETTATE (CostantiMappingDiagnostici.NUMERO_POLICY_RISPETTATE),
  62.    
  63.     NUMERO_POLICY_VIOLATE (CostantiMappingDiagnostici.NUMERO_POLICY_VIOLATE),
  64.    
  65.     NUMERO_POLICY_VIOLATE_WARNING_ONLY (CostantiMappingDiagnostici.NUMERO_POLICY_VIOLATE_WARNING_ONLY),
  66.    
  67.     NUMERO_POLICY_IN_ERRORE (CostantiMappingDiagnostici.NUMERO_POLICY_IN_ERRORE),
  68.    
  69.     TIPO_AUTENTICAZIONE (CostantiMappingDiagnostici.TIPO_AUTENTICAZIONE),
  70.    
  71.     TIPO_AUTORIZZAZIONE_CONTENUTI (CostantiMappingDiagnostici.TIPO_AUTORIZZAZIONE_CONTENUTI),
  72.    
  73.     TIPO_VALIDAZIONE_CONTENUTI (CostantiMappingDiagnostici.TIPO_VALIDAZIONE_CONTENUTI),
  74.    
  75.     TIPO_PROCESSAMENTO_MTOM_RICHIESTA (CostantiMappingDiagnostici.TIPO_PROCESSAMENTO_MTOM_RICHIESTA),
  76.    
  77.     TIPO_PROCESSAMENTO_MTOM_RISPOSTA (CostantiMappingDiagnostici.TIPO_PROCESSAMENTO_MTOM_RISPOSTA),
  78.    
  79.     TIPO_PROCESSAMENTO_MESSAGE_SECURITY_RICHIESTA (CostantiMappingDiagnostici.TIPO_PROCESSAMENTO_MESSAGE_SECURITY_RICHIESTA),
  80.    
  81.     TIPO_PROCESSAMENTO_MESSAGE_SECURITY_RISPOSTA (CostantiMappingDiagnostici.TIPO_PROCESSAMENTO_MESSAGE_SECURITY_RISPOSTA),
  82.    
  83.     AUTENTICAZIONE_IN_CACHE (CostantiMappingDiagnostici.AUTENTICAZIONE_IN_CACHE),
  84.    
  85.     AUTORIZZAZIONE_IN_CACHE (CostantiMappingDiagnostici.AUTORIZZAZIONE_IN_CACHE),
  86.    
  87.     AUTORIZZAZIONE_CONTENUTI_IN_CACHE (CostantiMappingDiagnostici.AUTORIZZAZIONE_CONTENUTI_IN_CACHE),
  88.    
  89.     TOKEN_POLICY (CostantiMappingDiagnostici.TOKEN_POLICY),
  90.    
  91.     TOKEN_POLICY_ACTIONS (CostantiMappingDiagnostici.TOKEN_POLICY_ACTIONS),
  92.    
  93.     TOKEN_POLICY_AUTENTCAZIONE (CostantiMappingDiagnostici.TOKEN_POLICY_AUTENTCAZIONE),
  94.    
  95.     RESPONSE_FROM_CACHE (CostantiMappingDiagnostici.RESPONSE_FROM_CACHE),
  96.    
  97.     TIPO_TRASFORMAZIONE_RICHIESTA (CostantiMappingDiagnostici.TIPO_TRASFORMAZIONE_RICHIESTA),
  98.    
  99.     TIPO_TRASFORMAZIONE_RISPOSTA (CostantiMappingDiagnostici.TIPO_TRASFORMAZIONE_RISPOSTA),
  100.    
  101.     AUTENTICAZIONE_TOKEN_IN_CACHE (CostantiMappingDiagnostici.AUTENTICAZIONE_TOKEN_IN_CACHE),
  102.    
  103.     AUTENTICAZIONE_FALLITA_MOTIVAZIONE (CostantiMappingDiagnostici.AUTENTICAZIONE_FALLITA_MOTIVAZIONE),
  104.    
  105.     MODI_TOKEN_AUTHORIZATION_IN_CACHE (CostantiMappingDiagnostici.MODI_TOKEN_AUTHORIZATION_IN_CACHE),
  106.    
  107.     MODI_TOKEN_INTEGRITY_IN_CACHE (CostantiMappingDiagnostici.MODI_TOKEN_INTEGRITY_IN_CACHE),
  108.    
  109.     MODI_TOKEN_AUDIT_IN_CACHE (CostantiMappingDiagnostici.MODI_TOKEN_AUDIT_IN_CACHE)
  110.    
  111.     ;
  112.    
  113.    
  114.     /** Value */
  115.     private java.lang.Integer position;
  116.     private String description;
  117.     private InfoDato info;
  118.     @Override
  119.     public java.lang.Integer getValue()
  120.     {
  121.         return this.position;
  122.     }
  123.     public java.lang.Integer getPosition() {
  124.         return this.position;
  125.     }
  126.     public String getDescription() {
  127.         return this.description;
  128.     }
  129.     public InfoDato getInfo() {
  130.         return this.info;
  131.     }


  132.     /** Official Constructor */
  133.     MappingRicostruzioneDiagnostici(InfoDato infoElementoTraccia)
  134.     {
  135.         this.position = infoElementoTraccia.getPosition();
  136.         this.description = infoElementoTraccia.getDescription();
  137.         this.info = infoElementoTraccia;
  138.     }


  139.    
  140.     @Override
  141.     public String toString(){
  142.         return this.position+"";
  143.     }
  144.     public boolean equals(java.lang.Integer object){
  145.         if(object==null)
  146.             return false;
  147.         return object.toString().equals(this.getValue().toString());    
  148.     }
  149.    
  150.        
  151.    
  152.     /** compatibility with the generated bean (reflection) */
  153.     public boolean equals(Object object,List<String> fieldsNotCheck){
  154.         if(fieldsNotCheck!=null) {
  155.             // nop
  156.         }
  157.         if( !(object instanceof MappingRicostruzioneDiagnostici) ){
  158.             throw new UtilsRuntimeException("Wrong type: "+object.getClass().getName());
  159.         }
  160.         return this.equals((object));
  161.     }
  162.     public String toString(boolean reportHTML){
  163.         if(reportHTML) {
  164.             // nop
  165.         }
  166.         return toString();
  167.     }
  168.     public String toString(boolean reportHTML,List<String> fieldsNotIncluded){
  169.         if(reportHTML || fieldsNotIncluded!=null) {
  170.             // nop
  171.         }
  172.         return toString();
  173.     }
  174.     public String diff(Object object,StringBuilder bf,boolean reportHTML){
  175.         if(object!=null || reportHTML) {
  176.             // nop
  177.         }
  178.         return bf.toString();
  179.     }
  180.     public String diff(Object object,StringBuilder bf,boolean reportHTML,List<String> fieldsNotIncluded){
  181.         if(object!=null || reportHTML || fieldsNotIncluded!=null) {
  182.             // nop
  183.         }
  184.         return bf.toString();
  185.     }
  186.    
  187.    
  188.     /** Utilities */
  189.    
  190.     public static java.lang.Integer[] toArray(){
  191.         java.lang.Integer[] res = new java.lang.Integer[values().length];
  192.         int i=0;
  193.         for (MappingRicostruzioneDiagnostici tmp : values()) {
  194.             res[i]=tmp.getValue();
  195.             i++;
  196.         }
  197.         return res;
  198.     }  
  199.     public static String[] toStringArray(){
  200.         String[] res = new String[values().length];
  201.         int i=0;
  202.         for (MappingRicostruzioneDiagnostici tmp : values()) {
  203.             res[i]=tmp.toString();
  204.             i++;
  205.         }
  206.         return res;
  207.     }
  208.     public static String[] toEnumNameArray(){
  209.         String[] res = new String[values().length];
  210.         int i=0;
  211.         for (MappingRicostruzioneDiagnostici tmp : values()) {
  212.             res[i]=tmp.name();
  213.             i++;
  214.         }
  215.         return res;
  216.     }
  217.    
  218.     public static boolean contains(java.lang.Integer value){
  219.         return toEnumConstant(value)!=null;
  220.     }
  221.    
  222.     public static MappingRicostruzioneDiagnostici toEnumConstant(java.lang.Integer value){
  223.         for (MappingRicostruzioneDiagnostici tmp : values()) {
  224.             if(tmp.getValue()!=null && value!=null && (tmp.getValue().intValue() == value.intValue())){
  225.                 return tmp;
  226.             }
  227.         }
  228.         return null;
  229.     }
  230.    
  231.     public static IEnumeration toEnumConstantFromString(String value){
  232.         for (MappingRicostruzioneDiagnostici tmp : values()) {
  233.             if(tmp.toString().equals(value)){
  234.                 return tmp;
  235.             }
  236.         }
  237.         return null;
  238.     }
  239. }