Designer 10.7 | webMethods Service Development Help | Working with Document Types | Creating an IS Document Type | Creating an IS Document Type from an XML Document, DTD, or XML Schema | Creating an IS Document Type from a DTD
 
Creating an IS Document Type from a DTD
When creating an IS document type from a DTD, keep in mind that Integration Server assumes that the DTD is UTF8-encoded. If the DTD is not UTF8-encoded, add the XML prolog to the top of the DTD and explicitly state the encoding. For example, for a DTD encoded in 8859-1, you would insert the following at the top of the document:
<?xml version="1.0" encoding="8859-1" ?>
*To create an IS document type from a DTD
1. In the Service Development perspective, select File > New > Document Type
2. In the New Document Type dialog box, select the folder in which you want to save the IS document type.
3. In the Element name field, type a name for the IS document type using any combination of letters, numbers, and/or the underscore character. For information about restricted characters, see About Element Names.
4. Click Next.
5. On the Select the Source Type panel, select DTD. Click Next.
6. On the Select a Source Location panel, under Source location, do one of the following next to File/URL:
*To create the IS document type from an DTD that resides on the Internet, type the URL of the resource. (The URL you specify must begin with http: or https:.)
*To create the IS document type from a DTD on your local file system, type in the path and file name, or click the Browse button to navigate to and select the file.
7. Click Next.
8. Under Select the root node, select the root element of the DTD.
9. Under Element reference handling, select one of the following:
*Select Only generate document types for elements with multiple references to instruct Integration Server to create a separate document type for a referenced element only when the DTD contains multiple references to that element.
If an element is referenced multiple times, Integration Server creates a separate document type for the element. Integration Server replaces each element reference with a document reference field.
If an element is referenced only once, Integration Server defines the element in line by replacing the element reference with a document field.
*Select Always generate document types for referenced elements to instruct Integration Server to always create a separate document type for a referenced element even if it is referenced only once. In the document type, Integration Server replaces each element reference with a document reference field.
10. Click Finish.
Integration Server generates the IS document type and IS schema. Designer displays any errors or warnings that occur during document type generation.