From b2cbe56b0984f64f022a790ce650221963ac535f Mon Sep 17 00:00:00 2001 From: sparkhi <4743002+sparkhi@users.noreply.github.com> Date: Wed, 7 Jan 2026 18:23:17 +0000 Subject: [PATCH] Corrected the results extraction in documentation --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 9d815418..7a3acfcd 100644 --- a/README.md +++ b/README.md @@ -75,7 +75,7 @@ Example Java code of using the CSV Validator through the Java API: csvReader, csvSchemaReader ) - List messages = validateWithStringNames + Result result = validateWithStringNames .usingCsvEncoding(csvEncoding, validateCsvEncoding) // should only be `true` if using UTF-8 encoding, otherwise it will throw an exception .usingCsvSchemaEncoding(csvSchemaEncoding) .usingFailFast(failFast) @@ -87,6 +87,8 @@ Example Java code of using the CSV Validator through the Java API: .usingMaxCharsPerCell(maxCharsPerCell) .runValidation(); +List messages = ((CsvValidatorJavaBridge.ValidationResult)(result)).errors(); + if(messages.isEmpty()) { System.out.println("All worked OK"); } else {