Good morning,
Do the various ipf validators have a mechanism for generating validation reports, or at least a list of all the errors? I'm trying to create a stand-alone validation suite that I can use to help trading partners improve their messages. Here is an example of an iti-38 validator I've created (where stringEntity contains an iti-38 response in xml):
InputStream inputStream = stringEntity.getContent();
JAXBContext jaxbContext = JAXBContext.newInstance(AdhocQueryResponse.class);
AdhocQueryResponse response = (AdhocQueryResponse) jaxbContext.createUnmarshaller().unmarshal(inputStream);
RegistryResponseValidator iti38Validator = new RegistryResponseValidator();
QueryResponse queryResponse = (QueryResponse) EbXML30Converters.convertToQueryResponse(response);
QueryResponseTransformer transformer = new QueryResponseTransformer(new EbXMLFactory30());
EbXMLQueryResponse ebXML = transformer.toEbXML(queryResponse);
iti38Validator.validate(ebXML, XCA.Interactions.ITI_38_ASYNC_RESPONSE);
That only produces the following output on a message I know has multiple errors (confirmed with gazelle - also, it appears like google's 'code' tag isn't a thing anymore).
[main] INFO ca.uhn.hl7v2.VersionLogger - HAPI version is: 2.3
[main] INFO ca.uhn.hl7v2.VersionLogger - Default Structure libraries found for HL7 versions 2.5,
[main] INFO ca.uhn.hl7v2.util.Home - hapi.home is set to /usr/jtc/validationtester/.
I'm likely engaging the validator wrong, but I'm not sure.
Thanks
Jason