From 43c7962ded00b96b8d220290e44670d6d77290b2 Mon Sep 17 00:00:00 2001 From: igorbeslic Date: Wed, 15 Oct 2025 18:32:05 +0200 Subject: [PATCH 1/9] 3288 commons-util - check for null, trim received value to avoid unwanted conversions and exceptions --- .../bytechef/commons/util/ConvertUtils.java | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/server/libs/core/commons/commons-util/src/main/java/com/bytechef/commons/util/ConvertUtils.java b/server/libs/core/commons/commons-util/src/main/java/com/bytechef/commons/util/ConvertUtils.java index 1022cc90b0b..1631c1de487 100644 --- a/server/libs/core/commons/commons-util/src/main/java/com/bytechef/commons/util/ConvertUtils.java +++ b/server/libs/core/commons/commons-util/src/main/java/com/bytechef/commons/util/ConvertUtils.java @@ -30,6 +30,7 @@ /** * @author Ivica Cardic + * @author Igor Beslic */ public class ConvertUtils { @@ -74,8 +75,14 @@ public static T convertValue(Object fromValue, TypeReference toValueTypeR } public static Object convertString(String str) { + if (str == null) { + return null; + } + + String trimmedString = str.trim(); + try { - return Integer.parseInt(str); + return Integer.parseInt(trimmedString); } catch (NumberFormatException e) { if (logger.isTraceEnabled()) { logger.trace(e.getMessage(), e); @@ -83,19 +90,19 @@ public static Object convertString(String str) { } try { - return Double.parseDouble(str); + return Double.parseDouble(trimmedString); } catch (NumberFormatException e) { if (logger.isTraceEnabled()) { logger.trace(e.getMessage(), e); } } - if (str.equalsIgnoreCase("true") || str.equalsIgnoreCase("false")) { - return Boolean.parseBoolean(str); + if (trimmedString.equalsIgnoreCase("true") || trimmedString.equalsIgnoreCase("false")) { + return Boolean.parseBoolean(trimmedString); } try { - return LocalDateTime.parse(str); + return LocalDateTime.parse(trimmedString); } catch (DateTimeParseException e) { if (logger.isTraceEnabled()) { logger.trace(e.getMessage(), e); @@ -103,7 +110,7 @@ public static Object convertString(String str) { } try { - return LocalDate.parse(str); + return LocalDate.parse(trimmedString); } catch (DateTimeParseException e) { if (logger.isTraceEnabled()) { logger.trace(e.getMessage(), e); From c6a00d859bde4f25bf14cb8db45b7e7f2113d449 Mon Sep 17 00:00:00 2001 From: igorbeslic Date: Wed, 15 Oct 2025 18:42:16 +0200 Subject: [PATCH 2/9] 3288 commons-util - test - convertString tests --- .../commons/util/ConvertUtilsTest.java | 102 ++++++++++++++++++ 1 file changed, 102 insertions(+) create mode 100644 server/libs/core/commons/commons-util/src/test/java/com/bytechef/commons/util/ConvertUtilsTest.java diff --git a/server/libs/core/commons/commons-util/src/test/java/com/bytechef/commons/util/ConvertUtilsTest.java b/server/libs/core/commons/commons-util/src/test/java/com/bytechef/commons/util/ConvertUtilsTest.java new file mode 100644 index 00000000000..6306a9c4b24 --- /dev/null +++ b/server/libs/core/commons/commons-util/src/test/java/com/bytechef/commons/util/ConvertUtilsTest.java @@ -0,0 +1,102 @@ +/* + * Copyright 2025 ByteChef + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.bytechef.commons.util; + +import java.time.LocalDate; +import java.time.LocalDateTime; +import java.util.List; +import org.assertj.core.api.Assertions; +import org.junit.jupiter.api.Test; + +/** + * @author Igor Beslic + */ +public class ConvertUtilsTest { + + @Test + public void testConvertString() { + + for (String integerString : List.of("435", "+435", "435 ", " 435 ", " 435")) { + Assertions.assertThat( + ConvertUtils.convertString(integerString)) + .isInstanceOf( + Integer.class) + .isEqualTo( + 435); + } + + for (String integerString : List.of("-125", " -125", "-125 ", " -125 ", " -125")) { + Assertions.assertThat( + ConvertUtils.convertString(integerString)) + .isInstanceOf( + Integer.class) + .isEqualTo( + -125); + } + + Assertions.assertThat( + ConvertUtils.convertString("452.45")) + .isInstanceOf( + Double.class) + .isEqualTo( + 452.45); + + for (String booleanString : List.of("TRUE", "true", "TruE", "truE", "trUE")) { + Assertions.assertThat( + ConvertUtils.convertString(booleanString)) + .isInstanceOf( + Boolean.class) + .isEqualTo( + Boolean.TRUE); + } + + for (String booleanString : List.of("FALSE", "false", "FAlse", "FALse", "falsE")) { + Assertions.assertThat( + ConvertUtils.convertString(booleanString)) + .isInstanceOf( + Boolean.class) + .isEqualTo( + Boolean.FALSE); + } + + Assertions.assertThat( + ConvertUtils.convertString("2011-12-03T10:15:30")) + .isInstanceOf( + LocalDateTime.class) + .isEqualTo( + LocalDateTime.of(2011, 12, 3, 10, 15, 30, 0)); + + Assertions.assertThat( + ConvertUtils.convertString("2011-12-03")) + .isInstanceOf( + LocalDate.class) + .isEqualTo( + LocalDate.of(2011, 12, 3)); + + Assertions.assertThat( + ConvertUtils.convertString("non convertable value")) + .isInstanceOf( + String.class) + .isEqualTo( + "non convertable value"); + + Assertions.assertThat( + ConvertUtils.convertString(null)) + .isNull(); + } + +} From de34bb389f418254a6855d8440ffe410b4920895 Mon Sep 17 00:00:00 2001 From: igorbeslic Date: Wed, 15 Oct 2025 19:10:14 +0200 Subject: [PATCH 3/9] 3288 commons-util - relly to functions --- .../bytechef/commons/util/ConvertUtils.java | 53 +++++++++---------- 1 file changed, 26 insertions(+), 27 deletions(-) diff --git a/server/libs/core/commons/commons-util/src/main/java/com/bytechef/commons/util/ConvertUtils.java b/server/libs/core/commons/commons-util/src/main/java/com/bytechef/commons/util/ConvertUtils.java index 1631c1de487..326285791d2 100644 --- a/server/libs/core/commons/commons-util/src/main/java/com/bytechef/commons/util/ConvertUtils.java +++ b/server/libs/core/commons/commons-util/src/main/java/com/bytechef/commons/util/ConvertUtils.java @@ -25,6 +25,8 @@ import java.time.LocalDate; import java.time.LocalDateTime; import java.time.format.DateTimeParseException; +import java.util.List; +import java.util.function.Function; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -81,45 +83,42 @@ public static Object convertString(String str) { String trimmedString = str.trim(); - try { - return Integer.parseInt(trimmedString); - } catch (NumberFormatException e) { - if (logger.isTraceEnabled()) { - logger.trace(e.getMessage(), e); - } - } + Object value = null; - try { - return Double.parseDouble(trimmedString); - } catch (NumberFormatException e) { - if (logger.isTraceEnabled()) { - logger.trace(e.getMessage(), e); + for (Function transformerFunction : parseFunctions) { + try { + value = transformerFunction.apply(trimmedString); + } catch (NumberFormatException | DateTimeParseException exception) { + if (logger.isTraceEnabled()) { + logger.trace(exception.getMessage(), exception); + } + + continue; } - } - if (trimmedString.equalsIgnoreCase("true") || trimmedString.equalsIgnoreCase("false")) { - return Boolean.parseBoolean(trimmedString); + if (value != null) { + return value; + } } - try { - return LocalDateTime.parse(trimmedString); - } catch (DateTimeParseException e) { - if (logger.isTraceEnabled()) { - logger.trace(e.getMessage(), e); - } + if (trimmedString.equalsIgnoreCase("true")) { + return Boolean.TRUE; } - try { - return LocalDate.parse(trimmedString); - } catch (DateTimeParseException e) { - if (logger.isTraceEnabled()) { - logger.trace(e.getMessage(), e); - } + if (trimmedString.equalsIgnoreCase("false")) { + return Boolean.FALSE; } return str; } + private static final List> parseFunctions; + + static { + parseFunctions = List.of( + Integer::parseInt, Long::parseLong, Double::parseDouble, LocalDateTime::parse, LocalDate::parse); + } + @SuppressFBWarnings("EI") public static void setObjectMapper(ObjectMapper objectMapper) { ConvertUtils.objectMapper = objectMapper; From 9211c33f864d730da732b510cb4b71915d79c778 Mon Sep 17 00:00:00 2001 From: igorbeslic Date: Wed, 15 Oct 2025 22:30:46 +0200 Subject: [PATCH 4/9] 3288 commons-util - javadocs - add method documentation --- .../java/com/bytechef/commons/util/ConvertUtils.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/server/libs/core/commons/commons-util/src/main/java/com/bytechef/commons/util/ConvertUtils.java b/server/libs/core/commons/commons-util/src/main/java/com/bytechef/commons/util/ConvertUtils.java index 326285791d2..88a1686eb64 100644 --- a/server/libs/core/commons/commons-util/src/main/java/com/bytechef/commons/util/ConvertUtils.java +++ b/server/libs/core/commons/commons-util/src/main/java/com/bytechef/commons/util/ConvertUtils.java @@ -76,6 +76,15 @@ public static T convertValue(Object fromValue, TypeReference toValueTypeR return objectMapper.convertValue(fromValue, toValueTypeRef); } + /** + * Converts the string value given with parameter to typed value. Conversion rellies on parse method of Integer, + * Long, Double, LocalDateTime and LocalDate methods. Boolean values are derived from case unsensitive true and + * false variants of value. + * + * @param str String representation of value + * @return value as Integer, Long, Double, LocalDateTime, LocalDate, Boolean, String or null if received method + * argument is null + */ public static Object convertString(String str) { if (str == null) { return null; From 0b10439035cb18bc67dada138431f54df1364b6a Mon Sep 17 00:00:00 2001 From: igorbeslic Date: Wed, 15 Oct 2025 23:49:06 +0200 Subject: [PATCH 5/9] 3288 csv-file - gradle - use commons-util --- server/libs/modules/components/csv-file/build.gradle.kts | 1 + 1 file changed, 1 insertion(+) diff --git a/server/libs/modules/components/csv-file/build.gradle.kts b/server/libs/modules/components/csv-file/build.gradle.kts index dc362bee0c2..140f8d87c06 100644 --- a/server/libs/modules/components/csv-file/build.gradle.kts +++ b/server/libs/modules/components/csv-file/build.gradle.kts @@ -3,6 +3,7 @@ version="1.0" dependencies { implementation("org.apache.commons:commons-lang3") implementation("com.fasterxml.jackson.dataformat:jackson-dataformat-csv") + implementation(project(":server:libs:core:commons:commons-util")) testImplementation(project(":server:libs:atlas:atlas-execution:atlas-execution-api")) testImplementation(project(":server:libs:atlas:atlas-file-storage:atlas-file-storage-api")) From 1e42f715ff06fb88988b72abf37a7f607c1a5ada Mon Sep 17 00:00:00 2001 From: igorbeslic Date: Wed, 15 Oct 2025 23:50:02 +0200 Subject: [PATCH 6/9] 3288 csv-file - use converter from commons-util (maintain code at one place, avoid duplication) --- .../csv/file/util/CsvFileReadUtils.java | 41 ++----------------- 1 file changed, 3 insertions(+), 38 deletions(-) diff --git a/server/libs/modules/components/csv-file/src/main/java/com/bytechef/component/csv/file/util/CsvFileReadUtils.java b/server/libs/modules/components/csv-file/src/main/java/com/bytechef/component/csv/file/util/CsvFileReadUtils.java index 3c5777223d3..f7e07f00f62 100644 --- a/server/libs/modules/components/csv-file/src/main/java/com/bytechef/component/csv/file/util/CsvFileReadUtils.java +++ b/server/libs/modules/components/csv-file/src/main/java/com/bytechef/component/csv/file/util/CsvFileReadUtils.java @@ -25,6 +25,7 @@ import static com.bytechef.component.csv.file.constant.CsvFileConstants.PAGE_SIZE; import static com.bytechef.component.csv.file.constant.CsvFileConstants.READ_AS_STRING; +import com.bytechef.commons.util.ConvertUtils; import com.bytechef.component.definition.Parameters; import com.fasterxml.jackson.databind.MappingIterator; import com.fasterxml.jackson.dataformat.csv.CsvParser; @@ -34,11 +35,11 @@ import java.util.LinkedHashMap; import java.util.List; import java.util.Map; -import org.apache.commons.lang3.BooleanUtils; import org.apache.commons.lang3.StringUtils; /** * @author Ivica Cardic + * @author Igor Beslic */ public class CsvFileReadUtils { @@ -154,7 +155,7 @@ public static Object processValue( if (readAsString) { value = valueString; } else { - value = valueOf(valueString); + value = ConvertUtils.convertString(valueString); } } @@ -169,40 +170,4 @@ public static String strip(String valueString, char enclosingCharacter) { return StringUtils.removeEnd(valueString, String.valueOf(enclosingCharacter)); } - @SuppressWarnings("PMD.EmptyCatchBlock") - public static Object valueOf(String string) { - Object value = null; - - try { - value = Integer.parseInt(string); - } catch (NumberFormatException nfe) { - // ignore - } - - if (value == null) { - try { - value = Long.parseLong(string); - } catch (NumberFormatException nfe) { - // ignore - } - } - - if (value == null) { - try { - value = Double.parseDouble(string); - } catch (NumberFormatException nfe) { - // ignore - } - } - - if (value == null) { - value = BooleanUtils.toBooleanObject(string); - } - - if (value == null) { - value = string; - } - - return value; - } } From 376b5ba53b671fd8cbafd03ed2d1311629ed9422 Mon Sep 17 00:00:00 2001 From: igorbeslic Date: Thu, 16 Oct 2025 00:02:00 +0200 Subject: [PATCH 7/9] 3288 csv-file - test - add failing csv samples --- .../sample_header_semicolon_delimiter.csv | 70 +++++++++++++++++++ .../sample_no_header_semicolon_delimiter.csv | 69 ++++++++++++++++++ 2 files changed, 139 insertions(+) create mode 100644 server/libs/modules/components/csv-file/src/test/resources/dependencies/csv-file/sample_header_semicolon_delimiter.csv create mode 100644 server/libs/modules/components/csv-file/src/test/resources/dependencies/csv-file/sample_no_header_semicolon_delimiter.csv diff --git a/server/libs/modules/components/csv-file/src/test/resources/dependencies/csv-file/sample_header_semicolon_delimiter.csv b/server/libs/modules/components/csv-file/src/test/resources/dependencies/csv-file/sample_header_semicolon_delimiter.csv new file mode 100644 index 00000000000..be042f1bae5 --- /dev/null +++ b/server/libs/modules/components/csv-file/src/test/resources/dependencies/csv-file/sample_header_semicolon_delimiter.csv @@ -0,0 +1,70 @@ +Isis/P number; category (NL);Name NL;posities;Category (FR);Name (FR);;Voorstel naam EN (informatief);;Call to action? GEEN = STEEDS TER INFO / DE BESTAANDE PROCESSEN (papier/tussenpersoon) BLIJVEN;; +LI_152_001;Administratie & Formulieren;Vragenlijst 80% optimalisatie;29;Administration & Formulaires;Questionnaire optimalisation 80%;32;Questionnaire 80% optimization;30;;; +LI_155_001;Offertes & Voorstellen;Simulatie 80% optimalisatie;27;Offres & Propositions;Simulation optimalisation 80%;29;Simulation 80% optimization;27;Info;; +LI_156_001;Contract & Beleid;Bijvoegselbrief;15;Contrat & Police;Lettre avenant ;15;Endorsement letter;18;Info;; +LI_157_001;Contract & Beleid;Bijvoegsel bij uw contract;26;Contrat & Police;Avenant à votre contrat;23;Endorsement to your contract;28;Info;; +LI_159_001;Administratie & Formulieren;Fiscaal attest;14;Administration & Formulaires;Attestation fiscale;19;Fiscal atttestation;19;Info;; +LI_160_001;Administratie & Formulieren;Fiscaal informatiedocument;26;Administration & Formulaires;Document d'information fiscale;30;Fiscal Information Document;27;Info;; +LI_161_001;Contract & Beleid;Verklaring niet-roker;21;Contrat & Police;Déclaration non-fumeur;22;Non-smoker declaration;22;Invulbaar doc (leeg of gevuld?);; +LI_163_001;Contract & Beleid;Verklaring voor uw financiële acceptatie;40;Contrat & Police;Déclaration en vue de l'acceptation financière;46;Declaration regarding your financial acceptance;47;Invulbaar doc (leeg of gevuld?);; +LI_164_001;Contract & Beleid;Verklaring fiscaal inwoner / FATCA (Foreign Account Tax Compliance Act);72;Contrat & Police;Déclaration résident fiscal / FATCA (Foreign Account Tax Compliance Act);72;Tax resident declaration / FATCA (Foreign Account Tax Compliance Act);69;Invulbaar doc (leeg of gevuld?);; +LI_166_001;Contract & Beleid;Verklaring Politiek Prominente Personen;39;Contrat & Police;Déclaration Personnes Politiquement Exposées;44;Declaration Politically exposed persons;39;Invulbaar doc (leeg of gevuld?);; +LI_167_001;Contract & Beleid;Verklaring uiteindelijke begunstigde(n) van een vennootschap;60;Contrat & Police;Déclaration de(s) bénéficiaire(s) effectif(s) d'une société;59;Declaration of the ultimate beneficial owner(s) of a company;60;Invulbaar doc (leeg of gevuld?);; +LI_168_001;Beheer & Opvolging;Einddatum van uw contract - (Her)berekening;44;Gestion & Suivi;Échéance finale de votre contrat - (re)calcul;45;End date of your contract - (re)calculation;43;Info;; +LI_169_001;Beheer & Opvolging;Einddatum van uw contract - begeleidende brief;46;Gestion & Suivi;Échéance finale de votre contrat - lettre d'accompagnement;58;End date of your contract - guiding letter;42;Info;; +LI_171_001;Contract & Beleid;Aanvraag tot wijziging tussenpersoon;36;Contrat & Police;Demande changement d'intermédiaire;34;Request change of intermediary;30;Info;; +LI_174_001;Contract & Beleid;Medische vragenlijst;20;Contrat & Police;Questionnaire médical;21;Medical questionnaire;21;Invulbaar doc (leeg of gevuld?);; +LI_175_001;Contract & Beleid;Instructies voor de arts bij het medisch onderzoek;50;Contrat & Police;Instructions destinées au médecin pour l'examen médical;55;Instructions for the doctor's medical examination;49;Invulbaar doc (leeg of gevuld?);; +LI_176_001;Administratie & Formulieren;Opvolging ontbrekende informatie;32;Administration & Formulaires;Suivi des informations manquantes ;34;Follow-up missing information;29;Te behandelen;; +LI_177_001;Administratie & Formulieren;Opvolging ontbrekende informatie;32;Administration & Formulaires;Suivi des informations manquantes;33;Follow-up missing information;29;Te behandelen;; +LI_181_001;Beheer & Opvolging;Kopie brief (mail) aanvraag aan de aannemende begunstigde;57;Gestion & Suivi;Copie lettre (mail) de demande au bénéficiaire acceptant;56;Copy letter of demand to the accepting beneficiary;50;Info;; +LI_182_001;Beheer & Opvolging;Uitnodiging tot verlenging of optimalisatie van uw VAPZ-contract;64;Gestion & Suivi;Invitation pour prolongation ou optimisation de votre contrat PLCI;66;Invitation to prolongation or optimisation of your contract ;60;Te behandelen;; +LI_183_001;Offertes & Voorstellen;Offerte tot wijziging van uw contract;37;Offres & Propositions;Offre de modification de votre contrat;38;Quotation for amendment of your contract;40;;; +LI_184_001;Contract & Beleid;Verklaring duaal pensioensparen - formulier;43;Contrat & Police;Déclaration d'épargne-pension duale - formulaire;48;Declaration dual pension saving - form;38;Invulbaar doc (leeg of gevuld?);; +LI_191_001;Contract & Beleid;Verklaring duaal pensioensparen - begeleidende brief;52;Contrat & Police;Déclaration d'épargne-pension duale - lettre d'accompagnement;61;Declaration dual pension saving - guiding letter;48;;; +LI_194_001;Offertes & Voorstellen;Scenario's 80% optimalisatie;28;Offres & Propositions;Scénarios optimalisation 80%;28;Scenarios 80% optimization;26;Info;; +LI_198_001;Beheer & Opvolging;Kopie brief (mail) bevestiging aan de aannemende begunstigde;60;Gestion & Suivi;Copie lettre (mail) de confirmation au bénéficiaire acceptant;61;Copy letter of confirmation to the accepting beneficiary;56;Info;; +LI_200_001;Beheer & Opvolging;Berekening van (gedeeltelijke) afkoop van uw contract;53;Gestion & Suivi;Calcul du rachat (partiel) de votre contrat;43;Calculation of the (partial) surrender of your contract;55;Te behandelen;; +LI_206_001;Contract & Beleid;Bijvoegsel bij uw contract - Annulatie;38;Contrat & Police;Avenant à votre contrat - annulation;36;Endorsement to your contract - annulation;41;Info;; +LI_208_001;Contract & Beleid;Bijvoegsel bij uw contract - toevoegen/schrappen aannemende begunstigde;71;Contrat & Police;Avenant à votre contrat - ajouter/supprimer bénéficiaire acceptant;66;Endorsement to your contract - adding/removing accepting beneficiary;68;;; +LI_209_001;Contract & Beleid;Bijvoegsel bij uw contract - wijziging van de begunstigde;57;Contrat & Police;Avenant à votre contrat - changement de bénéficiaire;52;Endorsement to your contract - modification of the beneficiary;62;Info;; +LI_213_001;Administratie & Formulieren;Mandaat SEPA Europese Domiciliëring;35;Administration & Formulaires;Mandat SEPA de domiciliation européenne;39;SEPA mandate;12;Te behandelen;; +LI_214_001;Administratie & Formulieren;Betalingsuitnodiging;20;Administration & Formulaires;Invitation à payer;18;Payment request;15;Te behandelen;; +LI_215_001;Offertes & Voorstellen;Offerte;7;Offres & Propositions;Offre  ;7;Quotation ;11;Info;; +LI_216_001;Offertes & Voorstellen;Verzekeringsvoorstel;20;Offres & Propositions;Proposition d'assurance;23;Insurance proposal;18;In te vulllen;; +LI_217_001;Contract & Beleid;Bijzondere voorwaarden bij uw contract;38;Contrat & Police;Conditions particulières de votre contrat;41;Special terms and conditions of your contract;45;Info;; +LI_220_001;Contract & Beleid;Adviesfiche Sparen en Beleggen;30;Contrat & Police;Fiche de conseil Epargne & Investissement;41;IDD Saving & Investment;23;;; +LI_221_001;Contract & Beleid;Adviesfiche Aanvullend pensioen ;32;Contrat & Police;Fiche de conseil Pension complémentaire;39;IDD Supplementary pension;25;;; +LI_222_001;Contract & Beleid;Verklaringen van de verzekerde;30;Contrat & Police;Déclarations de l’assuré;24;Declarations of the insured;27;In te vullen?;; +LI_225_001;Contract & Beleid;Bevestiging wijziging tussenpersoon;35;Contrat & Police;Confirmation changement d'intermédiaire;39;Confirmation of change intermediary;35;;; +LI_226_001;Contract & Beleid;Wijziging beleggingsstrategie - uw aanvraag;43;Contrat & Police;Modification de la stratégie d'investissement - votre demande;61;Modification of the investment strategy - your request;54;Info;; +LI_227_001;Contract & Beleid;Wijziging beleggingsstrategie - switch van de spaarreserve van uw contract;74;Contrat & Police;Modification de la stratégie d'investissement -résultat switch des réserves d'épargne de votre contrat;102;Modification of the investment strategy - switch result ;56;Info;; +LI_232_001;Beheer & Opvolging;Simulatie voorschot op uw contract;34;Gestion & Suivi;Simulation avance sur votre contrat;35;Advance simulation on your contract;35;Info;; +LI_233_001;Beheer & Opvolging;Aanvraag tot voorschot op uw contract - voorschotakte;53;Gestion & Suivi;Demande d'avance sur votre contrat - acte d'avance;50;Request of an advance on your contract - advance payment contract;65;Te behandelen;; +LI_234_001;Beheer & Opvolging;Einddatum van uw contract - berekening uit te keren bedrag;58;Gestion & Suivi;Échéance finale de votre contrat - calcul du montant à verser;61;End date of your contract - calculation of the amount to be paid;64;Info;; +LI_236_001;Administratie & Formulieren;Intrest voorschot - herinnering;31;Administration & Formulaires;Intérêts sur avance - rappel;28;Interest payment - reminder;27;Te behandelen;; +LI_237_001;Administratie & Formulieren;Intrest voorschot - laatste herinnering;39;Administration & Formulaires;Intérêts sur avance - dernier rappel;36;Interest payment - final reminder;33;Te behandelen;; +LI_238_001;Administratie & Formulieren;Intrest voorschot - betalingsuitnodiging;40;Administration & Formulaires;Intérêts sur avance - invitation à payer;40;Interest payment - payment request;34;Te behandelen;; +LI_239_001;Beheer & Opvolging;(Gedeeltelijke) Afkoop van uw contract - simulatie;50;Gestion & Suivi;Rachat (partiel) de votre contrat - simulation;46;(Partial) surrender of your contract - simulation;49;Info;; +LI_241_001;Beheer & Opvolging;Uw aanvraag reserveoverdracht;29;Gestion & Suivi;Votre demande de transfer de réserves;37;Your request to transfer reserves;33;Info;; +LI_242_001;Beheer & Opvolging;Bevestiging reserveoverdracht;29;Gestion & Suivi;Confirmation transfert de réserves;34;Confirmation of transfer reserves;33;Info;; +LI_243_001;Offertes & Voorstellen;Offerte - bijlage rendementsberekening;38;Offres & Propositions;Offre - annexe calcul du rendement;34;Quotation - appendix return calculation;39;Info;; +LI_245_001;Contract & Beleid;Medische vragenlijst;20;Contrat & Police;Questionnaire médical;21;Medical questionnaire;21;Te behandelen;; +LI_246_001;Administratie & Formulieren;Terugbetaling van premie;24;Administration & Formulaires;Remboursement de prime;22;Premium refund;14;Info;; +LI_247_001;Administratie & Formulieren;Betalingsuitnodiging;20;Administration & Formulaires;Invitation à payer;18;Payment request;15;Te behandelen;; +LI_248_001;Contract & Beleid;Samenvatting van uw contract;28;Contrat & Police;Résumé de votre contrat;23;Contract summary ;17;Info;; +LI_250_001;Administratie & Formulieren;Betalingsuitnodiging - terugbetaling voorschot;46;Administration & Formulaires;Demande de paiement - remboursement d'avance;44;Payment request - refund of an advance;38;Te behandelen;; +LI_251_001;Beheer & Opvolging;Uw aanvraag reserveoverdracht - berekening;42;Gestion & Suivi;Votre demande de transfert de réserves - calcul;47;Your request to transfer reserves - calculation;47;Info;; +LI_252_001;Offertes & Voorstellen;Offerte;7;Offres & Propositions;Offre;5;Quotation;9;Info;; +LI_253_001;Offertes & Voorstellen;Verzekeringsvoorstel;20;Offres & Propositions;Proposition d'assurance;23;Insurance proposal;18;Te behandelen;; +LI_254_001;Contract & Beleid;Bijzondere voorwaarden bij uw contract;38;Contrat & Police;Conditions particulières de votre contrat;41;Special terms and conditions of your contract;45;Info;; +LI_255_001;Contract & Beleid;Adviesfiche Overlijden;22;Contrat & Police;Fiche de conseil Décès;22;IDD Death;9;;; +LI_256_001;Contract & Beleid;Adviesfiche Arbeidsongeschiktheid;33;Contrat & Police;Fiche de conseil Incapacité de travail;38;IDD Disability;14;;; +LI_257_001;Contract & Beleid;Verklaring gewaarborgd inkomen - omzet & kosten;47;Contrat & Police;Déclaration revenu garanti - chiffre d'affaires & frais;55;Declaration guaranteed income - turnover and costs;50;In te vullen ;; +LI_258_001;Contract & Beleid;Bijvoegsel bij uw contract;26;Contrat & Police;Avenant à votre contrat;23;Endorsement to your contract;28;Info;; +LI_260_001;Contract & Beleid;Offerte tot wijziging van uw contract;37;Contrat & Police;Offre de modification de votre contrat;38;Quotation to modify your contract;33;Info;; +LI_261_001;Beheer & Opvolging;Jaarlijks certficaat;20;Gestion & Suivi;Attestation annuelle;20;Yearly certificate (profit);27;Info;; +LI_262_001;Beheer & Opvolging;Pensioenfiche;13;Gestion & Suivi;Fiche de pension;16;Pension statement (profit);26;Info;; +LI_263_001;Beheer & Opvolging;Jaarlijks certificaat - begeleidende brief / Pensioenfiche - begeleidende brief;79;Gestion & Suivi;Attestation annuelle - lettre d'accompagnement / Fiche de pension - lettre d'accompagnement;91;Yearly certificate - guiding letter / Pension statement - guiding letter;72;Info;; +LI_264_001;Beheer & Opvolging;Overzicht rendement tak 23-fondsen;34;Gestion & Suivi;Aperçu des rendements fonds branche 23;38;Overview of returns for branch 23 funds;39;Info;; +LI_265_001;Contract & Beleid;Bijvoegsel tot vernietiging van uw contract;43;Contrat & Police;Avenant d’annulation de votre contrat;37;Endorsement to cancel your contract;35;Info;; diff --git a/server/libs/modules/components/csv-file/src/test/resources/dependencies/csv-file/sample_no_header_semicolon_delimiter.csv b/server/libs/modules/components/csv-file/src/test/resources/dependencies/csv-file/sample_no_header_semicolon_delimiter.csv new file mode 100644 index 00000000000..ab3a98033a8 --- /dev/null +++ b/server/libs/modules/components/csv-file/src/test/resources/dependencies/csv-file/sample_no_header_semicolon_delimiter.csv @@ -0,0 +1,69 @@ +LI_152_001;Administratie & Formulieren;Vragenlijst 80% optimalisatie;29;Administration & Formulaires;Questionnaire optimalisation 80%;32;Questionnaire 80% optimization;30;;; +LI_155_001;Offertes & Voorstellen;Simulatie 80% optimalisatie;27;Offres & Propositions;Simulation optimalisation 80%;29;Simulation 80% optimization;27;Info;; +LI_156_001;Contract & Beleid;Bijvoegselbrief;15;Contrat & Police;Lettre avenant ;15;Endorsement letter;18;Info;; +LI_157_001;Contract & Beleid;Bijvoegsel bij uw contract;26;Contrat & Police;Avenant à votre contrat;23;Endorsement to your contract;28;Info;; +LI_159_001;Administratie & Formulieren;Fiscaal attest;14;Administration & Formulaires;Attestation fiscale;19;Fiscal atttestation;19;Info;; +LI_160_001;Administratie & Formulieren;Fiscaal informatiedocument;26;Administration & Formulaires;Document d'information fiscale;30;Fiscal Information Document;27;Info;; +LI_161_001;Contract & Beleid;Verklaring niet-roker;21;Contrat & Police;Déclaration non-fumeur;22;Non-smoker declaration;22;Invulbaar doc (leeg of gevuld?);; +LI_163_001;Contract & Beleid;Verklaring voor uw financiële acceptatie;40;Contrat & Police;Déclaration en vue de l'acceptation financière;46;Declaration regarding your financial acceptance;47;Invulbaar doc (leeg of gevuld?);; +LI_164_001;Contract & Beleid;Verklaring fiscaal inwoner / FATCA (Foreign Account Tax Compliance Act);72;Contrat & Police;Déclaration résident fiscal / FATCA (Foreign Account Tax Compliance Act);72;Tax resident declaration / FATCA (Foreign Account Tax Compliance Act);69;Invulbaar doc (leeg of gevuld?);; +LI_166_001;Contract & Beleid;Verklaring Politiek Prominente Personen;39;Contrat & Police;Déclaration Personnes Politiquement Exposées;44;Declaration Politically exposed persons;39;Invulbaar doc (leeg of gevuld?);; +LI_167_001;Contract & Beleid;Verklaring uiteindelijke begunstigde(n) van een vennootschap;60;Contrat & Police;Déclaration de(s) bénéficiaire(s) effectif(s) d'une société;59;Declaration of the ultimate beneficial owner(s) of a company;60;Invulbaar doc (leeg of gevuld?);; +LI_168_001;Beheer & Opvolging;Einddatum van uw contract - (Her)berekening;44;Gestion & Suivi;Échéance finale de votre contrat - (re)calcul;45;End date of your contract - (re)calculation;43;Info;; +LI_169_001;Beheer & Opvolging;Einddatum van uw contract - begeleidende brief;46;Gestion & Suivi;Échéance finale de votre contrat - lettre d'accompagnement;58;End date of your contract - guiding letter;42;Info;; +LI_171_001;Contract & Beleid;Aanvraag tot wijziging tussenpersoon;36;Contrat & Police;Demande changement d'intermédiaire;34;Request change of intermediary;30;Info;; +LI_174_001;Contract & Beleid;Medische vragenlijst;20;Contrat & Police;Questionnaire médical;21;Medical questionnaire;21;Invulbaar doc (leeg of gevuld?);; +LI_175_001;Contract & Beleid;Instructies voor de arts bij het medisch onderzoek;50;Contrat & Police;Instructions destinées au médecin pour l'examen médical;55;Instructions for the doctor's medical examination;49;Invulbaar doc (leeg of gevuld?);; +LI_176_001;Administratie & Formulieren;Opvolging ontbrekende informatie;32;Administration & Formulaires;Suivi des informations manquantes ;34;Follow-up missing information;29;Te behandelen;; +LI_177_001;Administratie & Formulieren;Opvolging ontbrekende informatie;32;Administration & Formulaires;Suivi des informations manquantes;33;Follow-up missing information;29;Te behandelen;; +LI_181_001;Beheer & Opvolging;Kopie brief (mail) aanvraag aan de aannemende begunstigde;57;Gestion & Suivi;Copie lettre (mail) de demande au bénéficiaire acceptant;56;Copy letter of demand to the accepting beneficiary;50;Info;; +LI_182_001;Beheer & Opvolging;Uitnodiging tot verlenging of optimalisatie van uw VAPZ-contract;64;Gestion & Suivi;Invitation pour prolongation ou optimisation de votre contrat PLCI;66;Invitation to prolongation or optimisation of your contract ;60;Te behandelen;; +LI_183_001;Offertes & Voorstellen;Offerte tot wijziging van uw contract;37;Offres & Propositions;Offre de modification de votre contrat;38;Quotation for amendment of your contract;40;;; +LI_184_001;Contract & Beleid;Verklaring duaal pensioensparen - formulier;43;Contrat & Police;Déclaration d'épargne-pension duale - formulaire;48;Declaration dual pension saving - form;38;Invulbaar doc (leeg of gevuld?);; +LI_191_001;Contract & Beleid;Verklaring duaal pensioensparen - begeleidende brief;52;Contrat & Police;Déclaration d'épargne-pension duale - lettre d'accompagnement;61;Declaration dual pension saving - guiding letter;48;;; +LI_194_001;Offertes & Voorstellen;Scenario's 80% optimalisatie;28;Offres & Propositions;Scénarios optimalisation 80%;28;Scenarios 80% optimization;26;Info;; +LI_198_001;Beheer & Opvolging;Kopie brief (mail) bevestiging aan de aannemende begunstigde;60;Gestion & Suivi;Copie lettre (mail) de confirmation au bénéficiaire acceptant;61;Copy letter of confirmation to the accepting beneficiary;56;Info;; +LI_200_001;Beheer & Opvolging;Berekening van (gedeeltelijke) afkoop van uw contract;53;Gestion & Suivi;Calcul du rachat (partiel) de votre contrat;43;Calculation of the (partial) surrender of your contract;55;Te behandelen;; +LI_206_001;Contract & Beleid;Bijvoegsel bij uw contract - Annulatie;38;Contrat & Police;Avenant à votre contrat - annulation;36;Endorsement to your contract - annulation;41;Info;; +LI_208_001;Contract & Beleid;Bijvoegsel bij uw contract - toevoegen/schrappen aannemende begunstigde;71;Contrat & Police;Avenant à votre contrat - ajouter/supprimer bénéficiaire acceptant;66;Endorsement to your contract - adding/removing accepting beneficiary;68;;; +LI_209_001;Contract & Beleid;Bijvoegsel bij uw contract - wijziging van de begunstigde;57;Contrat & Police;Avenant à votre contrat - changement de bénéficiaire;52;Endorsement to your contract - modification of the beneficiary;62;Info;; +LI_213_001;Administratie & Formulieren;Mandaat SEPA Europese Domiciliëring;35;Administration & Formulaires;Mandat SEPA de domiciliation européenne;39;SEPA mandate;12;Te behandelen;; +LI_214_001;Administratie & Formulieren;Betalingsuitnodiging;20;Administration & Formulaires;Invitation à payer;18;Payment request;15;Te behandelen;; +LI_215_001;Offertes & Voorstellen;Offerte;7;Offres & Propositions;Offre  ;7;Quotation ;11;Info;; +LI_216_001;Offertes & Voorstellen;Verzekeringsvoorstel;20;Offres & Propositions;Proposition d'assurance;23;Insurance proposal;18;In te vulllen;; +LI_217_001;Contract & Beleid;Bijzondere voorwaarden bij uw contract;38;Contrat & Police;Conditions particulières de votre contrat;41;Special terms and conditions of your contract;45;Info;; +LI_220_001;Contract & Beleid;Adviesfiche Sparen en Beleggen;30;Contrat & Police;Fiche de conseil Epargne & Investissement;41;IDD Saving & Investment;23;;; +LI_221_001;Contract & Beleid;Adviesfiche Aanvullend pensioen ;32;Contrat & Police;Fiche de conseil Pension complémentaire;39;IDD Supplementary pension;25;;; +LI_222_001;Contract & Beleid;Verklaringen van de verzekerde;30;Contrat & Police;Déclarations de l’assuré;24;Declarations of the insured;27;In te vullen?;; +LI_225_001;Contract & Beleid;Bevestiging wijziging tussenpersoon;35;Contrat & Police;Confirmation changement d'intermédiaire;39;Confirmation of change intermediary;35;;; +LI_226_001;Contract & Beleid;Wijziging beleggingsstrategie - uw aanvraag;43;Contrat & Police;Modification de la stratégie d'investissement - votre demande;61;Modification of the investment strategy - your request;54;Info;; +LI_227_001;Contract & Beleid;Wijziging beleggingsstrategie - switch van de spaarreserve van uw contract;74;Contrat & Police;Modification de la stratégie d'investissement -résultat switch des réserves d'épargne de votre contrat;102;Modification of the investment strategy - switch result ;56;Info;; +LI_232_001;Beheer & Opvolging;Simulatie voorschot op uw contract;34;Gestion & Suivi;Simulation avance sur votre contrat;35;Advance simulation on your contract;35;Info;; +LI_233_001;Beheer & Opvolging;Aanvraag tot voorschot op uw contract - voorschotakte;53;Gestion & Suivi;Demande d'avance sur votre contrat - acte d'avance;50;Request of an advance on your contract - advance payment contract;65;Te behandelen;; +LI_234_001;Beheer & Opvolging;Einddatum van uw contract - berekening uit te keren bedrag;58;Gestion & Suivi;Échéance finale de votre contrat - calcul du montant à verser;61;End date of your contract - calculation of the amount to be paid;64;Info;; +LI_236_001;Administratie & Formulieren;Intrest voorschot - herinnering;31;Administration & Formulaires;Intérêts sur avance - rappel;28;Interest payment - reminder;27;Te behandelen;; +LI_237_001;Administratie & Formulieren;Intrest voorschot - laatste herinnering;39;Administration & Formulaires;Intérêts sur avance - dernier rappel;36;Interest payment - final reminder;33;Te behandelen;; +LI_238_001;Administratie & Formulieren;Intrest voorschot - betalingsuitnodiging;40;Administration & Formulaires;Intérêts sur avance - invitation à payer;40;Interest payment - payment request;34;Te behandelen;; +LI_239_001;Beheer & Opvolging;(Gedeeltelijke) Afkoop van uw contract - simulatie;50;Gestion & Suivi;Rachat (partiel) de votre contrat - simulation;46;(Partial) surrender of your contract - simulation;49;Info;; +LI_241_001;Beheer & Opvolging;Uw aanvraag reserveoverdracht;29;Gestion & Suivi;Votre demande de transfer de réserves;37;Your request to transfer reserves;33;Info;; +LI_242_001;Beheer & Opvolging;Bevestiging reserveoverdracht;29;Gestion & Suivi;Confirmation transfert de réserves;34;Confirmation of transfer reserves;33;Info;; +LI_243_001;Offertes & Voorstellen;Offerte - bijlage rendementsberekening;38;Offres & Propositions;Offre - annexe calcul du rendement;34;Quotation - appendix return calculation;39;Info;; +LI_245_001;Contract & Beleid;Medische vragenlijst;20;Contrat & Police;Questionnaire médical;21;Medical questionnaire;21;Te behandelen;; +LI_246_001;Administratie & Formulieren;Terugbetaling van premie;24;Administration & Formulaires;Remboursement de prime;22;Premium refund;14;Info;; +LI_247_001;Administratie & Formulieren;Betalingsuitnodiging;20;Administration & Formulaires;Invitation à payer;18;Payment request;15;Te behandelen;; +LI_248_001;Contract & Beleid;Samenvatting van uw contract;28;Contrat & Police;Résumé de votre contrat;23;Contract summary ;17;Info;; +LI_250_001;Administratie & Formulieren;Betalingsuitnodiging - terugbetaling voorschot;46;Administration & Formulaires;Demande de paiement - remboursement d'avance;44;Payment request - refund of an advance;38;Te behandelen;; +LI_251_001;Beheer & Opvolging;Uw aanvraag reserveoverdracht - berekening;42;Gestion & Suivi;Votre demande de transfert de réserves - calcul;47;Your request to transfer reserves - calculation;47;Info;; +LI_252_001;Offertes & Voorstellen;Offerte;7;Offres & Propositions;Offre;5;Quotation;9;Info;; +LI_253_001;Offertes & Voorstellen;Verzekeringsvoorstel;20;Offres & Propositions;Proposition d'assurance;23;Insurance proposal;18;Te behandelen;; +LI_254_001;Contract & Beleid;Bijzondere voorwaarden bij uw contract;38;Contrat & Police;Conditions particulières de votre contrat;41;Special terms and conditions of your contract;45;Info;; +LI_255_001;Contract & Beleid;Adviesfiche Overlijden;22;Contrat & Police;Fiche de conseil Décès;22;IDD Death;9;;; +LI_256_001;Contract & Beleid;Adviesfiche Arbeidsongeschiktheid;33;Contrat & Police;Fiche de conseil Incapacité de travail;38;IDD Disability;14;;; +LI_257_001;Contract & Beleid;Verklaring gewaarborgd inkomen - omzet & kosten;47;Contrat & Police;Déclaration revenu garanti - chiffre d'affaires & frais;55;Declaration guaranteed income - turnover and costs;50;In te vullen ;; +LI_258_001;Contract & Beleid;Bijvoegsel bij uw contract;26;Contrat & Police;Avenant à votre contrat;23;Endorsement to your contract;28;Info;; +LI_260_001;Contract & Beleid;Offerte tot wijziging van uw contract;37;Contrat & Police;Offre de modification de votre contrat;38;Quotation to modify your contract;33;Info;; +LI_261_001;Beheer & Opvolging;Jaarlijks certficaat;20;Gestion & Suivi;Attestation annuelle;20;Yearly certificate (profit);27;Info;; +LI_262_001;Beheer & Opvolging;Pensioenfiche;13;Gestion & Suivi;Fiche de pension;16;Pension statement (profit);26;Info;; +LI_263_001;Beheer & Opvolging;Jaarlijks certificaat - begeleidende brief / Pensioenfiche - begeleidende brief;79;Gestion & Suivi;Attestation annuelle - lettre d'accompagnement / Fiche de pension - lettre d'accompagnement;91;Yearly certificate - guiding letter / Pension statement - guiding letter;72;Info;; +LI_264_001;Beheer & Opvolging;Overzicht rendement tak 23-fondsen;34;Gestion & Suivi;Aperçu des rendements fonds branche 23;38;Overview of returns for branch 23 funds;39;Info;; +LI_265_001;Contract & Beleid;Bijvoegsel tot vernietiging van uw contract;43;Contrat & Police;Avenant d’annulation de votre contrat;37;Endorsement to cancel your contract;35;Info;; From 6be0b6a4c123e19f33e818ca76304a279d61bfef Mon Sep 17 00:00:00 2001 From: igorbeslic Date: Thu, 16 Oct 2025 00:02:24 +0200 Subject: [PATCH 8/9] 3288 csv-file - test - add new test to process failing samples --- .../file/CsvFileComponentHandlerIntTest.java | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/server/libs/modules/components/csv-file/src/test/java/com/bytechef/component/csv/file/CsvFileComponentHandlerIntTest.java b/server/libs/modules/components/csv-file/src/test/java/com/bytechef/component/csv/file/CsvFileComponentHandlerIntTest.java index 00a1f090bc8..aacfdc0338f 100644 --- a/server/libs/modules/components/csv-file/src/test/java/com/bytechef/component/csv/file/CsvFileComponentHandlerIntTest.java +++ b/server/libs/modules/components/csv-file/src/test/java/com/bytechef/component/csv/file/CsvFileComponentHandlerIntTest.java @@ -35,6 +35,7 @@ import java.util.Base64; import java.util.List; import java.util.Map; +import org.assertj.core.api.Assertions; import org.assertj.core.util.Files; import org.json.JSONArray; import org.json.JSONException; @@ -43,6 +44,7 @@ /** * @author Ivica Cardic + * @author Igor Beslic */ @ComponentIntTest class CsvFileComponentHandlerIntTest { @@ -156,6 +158,27 @@ void testReadHeaderAndDelimiter() throws JSONException { true); } + @Test + void testReadHeaderAndDelimiterAdvanced() throws JSONException { + File sampleFile = getFile("sample_header_semicolon_delimiter.csv"); + + Job job = componentJobTestExecutor.execute( + ENCODER.encodeToString("csv-file_v1_read".getBytes(StandardCharsets.UTF_8)), + Map.of( + FILE_ENTRY, + tempFileStorage.storeFileContent( + sampleFile.getAbsolutePath(), Files.contentOf(sampleFile, StandardCharsets.UTF_8)), + INCLUDE_EMPTY_CELLS, true, DELIMITER, ";", + HEADER_ROW, true)); + + assertThat(job.getStatus()).isEqualTo(Job.Status.COMPLETED); + + Map outputs = taskFileStorage.readJobOutputs(job.getOutputs()); + + Assertions.assertThat(((Map) ((List) outputs.get("readCsvFile")).getFirst()).size()) + .isEqualTo(11); + } + // @Test public void testWrite() throws JSONException { Job job = componentJobTestExecutor.execute( From 094e11bc60ae28d19d909a68d7c45ae47ad6431d Mon Sep 17 00:00:00 2001 From: igorbeslic Date: Thu, 16 Oct 2025 00:03:58 +0200 Subject: [PATCH 9/9] 3288 csv-file - if any column in header row is empty, us column_ convention --- .../component/csv/file/util/CsvFileReadUtils.java | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/server/libs/modules/components/csv-file/src/main/java/com/bytechef/component/csv/file/util/CsvFileReadUtils.java b/server/libs/modules/components/csv-file/src/main/java/com/bytechef/component/csv/file/util/CsvFileReadUtils.java index f7e07f00f62..ebca5cd0711 100644 --- a/server/libs/modules/components/csv-file/src/main/java/com/bytechef/component/csv/file/util/CsvFileReadUtils.java +++ b/server/libs/modules/components/csv-file/src/main/java/com/bytechef/component/csv/file/util/CsvFileReadUtils.java @@ -76,12 +76,22 @@ public static Map getHeaderRow( Map map = new LinkedHashMap<>(); + int currColumn = 1; + for (Map.Entry entry : row.entrySet()) { + String strippedString = strip((String) entry.getKey(), enclosingCharacter); + + if (strippedString.isEmpty()) { + strippedString = "column_" + currColumn; + } + map.put( - strip((String) entry.getKey(), enclosingCharacter), + strippedString, processValue( (String) entry.getValue(), enclosingCharacter, configuration.includeEmptyCells(), configuration.readAsString())); + + currColumn++; } return map;