Usingthe Schematron API

Performthe following to invoke the schematron API from a Java Collaboration:
Obtainingthe Factory Object
Obtainingthe Validator Object
Performingthe Validation

Obtainingthe Factory Object

Belowis a sample call to the getSchematronValidatorFactory method.
com.stc.connector.hl7.schematron.SchematronValidatorFactory
factory = com.stc.connector.hl7.schematron.SchematronValidatorFactory.
getSchematronValidatorFactory();

Obtainingthe Validator Object

Belowis a sample call to the getDefaultValidator method.
com.stc.connector.hl7.schematron.SchematronValidator
validator = factory.getDefaultValidator( domSource );
Inthe above example, domSource is the DOMSource object of the schematron XML.

Performingthe Validation

Belowis a sample call to the validate method.
com.stc.connector.hl7.schematron.ValidationOutput
output = validator.validate( dataSrc );
Inthe above example, dataSrc is the source of the payload. The payload can be an entire V3
XMLdocument or a CDA document.
TheValidationOutput object contains the resulting XML document as well as a method
isValid(),which returns values when the validation has passed or failed.
Addingand Conguring a TCP/IP HL7 Adapter in aConnectivity Map
AllAdapters contain a set of properties that are unique to that Adapter type. When you add a
TCP/IPHL7 Adapter to a Connectivity Map, you can modify the properties for that specic
Adapter.When you add a TCP/IP HL7 External System in the Project’sEnvironment, you can
modifythe properties for that Adapter type for all Projects that use that Environment.
AddingandConguring a TCP/IP HL7 Adapter in a Connectivity Map
SunAdapterfor TCP/IP HL7 User's Guide 27