You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi everyone!
I'm getting a strange error when trying to validate a BDOC container:
My code:
Containercontainer = ContainerBuilder.aContainer(DocumentType.BDOC)
.fromExistingFile(bdocFileName)
.build();
// Validate the containerContainerValidationResultresult = container.validate();
// Check if the container is validbooleanisContainerValid = result.isValid();
// Get the validation errors and warningsList<DigiDoc4JException> validationErrors = result.getErrors();
List<DigiDoc4JException> validationWarnings = result.getWarnings();
List<DigiDoc4JException> containerErrors = result.getContainerErrors();// Container format errorsList<DigiDoc4JException> containerWarnings = result.getContainerWarnings();
StringvalidationReport = result.getReport();
result.saveXmlReports(reportFileName));
System.out.println(validationErrors);
I think that the issue might concern this function in the ContainerOpener.java class:
In fact, in the read() function at line 126 it crushes by throwing the mentioned exception, assuming that it is an ASIC container before doing the checks that would follow.
Am I doing something wrong?
The text was updated successfully, but these errors were encountered:
Is the mime type of the container defined as application/vnd.bdoc-1.0 (found in mimetype file)?
Could you please send your container to [email protected] so we can analyze further.
Today DigiDoc4j does support only ASIC-E standard based BDOC containers and in accordance of BDOC2.1 standard only mime type application/vnd.etsi.asic-e+zip is allowed.
More information on the subject can be found here:
Hi everyone!
I'm getting a strange error when trying to validate a BDOC container:
My code:
I think that the issue might concern this function in the ContainerOpener.java class:
In fact, in the read() function at line 126 it crushes by throwing the mentioned exception, assuming that it is an ASIC container before doing the checks that would follow.
Am I doing something wrong?
The text was updated successfully, but these errors were encountered: