ParserResult.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.utils.csv;
  21. import java.util.ArrayList;
  22. import java.util.List;
  23. import java.util.Map;

  24. /**
  25.  * ParserResult
  26.  *
  27.  * @author Andrea Poli (apoli@link.it)
  28.  * @author $Author$
  29.  * @version $Rev$, $Date$
  30.  */
  31. public class ParserResult {

  32.     private Map<String, Integer> headerMap = null;
  33.     private List<Record> records = new ArrayList<Record>();

  34.     public List<Record> getRecords() {
  35.         return this.records;
  36.     }
  37.     public void setRecords(List<Record> records) {
  38.         this.records = records;
  39.     }
  40.    
  41.     public boolean existsHeader(){
  42.         return this.headerMap!=null && this.headerMap.size()>0;
  43.     }
  44.     public Map<String, Integer> getHeaderMap() {
  45.         return this.headerMap;
  46.     }
  47.     public void setHeaderMap(Map<String, Integer> headerMap) {
  48.         this.headerMap = headerMap;
  49.     }
  50.    
  51.    
  52. }