Trading Networks 10.3 | Administering and Monitoring B2B Transactions | webMethods Module for EDI | Creating Clients that Send EDI Documents to Integration Server | Creating the Service the Client Invokes to Handle EDI Documents | Validating the Input Internal-Format Document When It Is an IData Object
 
Validating the Input Internal-Format Document When It Is an IData Object
The logic in the sample code for forming an EDI document from an internal-format document assumes the internal-format document is passed to your service as a String or InputStream. In this situation, you can have the wm.b2b.edi:convertToValues service validate the document. If your client passes the internal-format document to your service as an IData object, and you want to validate the internal-format document before converting it to an EDI document, you can replace the logic that invokes the convertToValues service with logic that uses the pub.schema:validate service, as shown in the following diagram:
When you use the pub.schema:validate service, you must have an IS document type that defines the structure of the internal-format document. For more information about the pub.schema:validate service, see the webMethods Integration Server Built-In Services Reference for your release.