Designer 10.7 | webMethods Service Development Help | Working with Document Types | Creating an IS Document Type | Creating an IS Document Type from an E-form Template
 
Creating an IS Document Type from an E-form Template
 
Notes About IS Document Types Created from E-form Templates
You can create a publishable IS document type from an e-form template stored on the file system or in a content repository.
Keep the following information in mind when creating an IS document type from an e-form template:
*To use an e-form in a repository as the source, a content repository must be set up and the e-form environment must be deployed to the Integration Server on which you want to create the IS document type. For more information about configuring and deploying an e-forms environment, see Implementing E-form Support for BPM.
*When creating an IS document type from an e-form template, Integration Server extracts an XML schema definition from the template and uses the XML schema definition to create the IS document type and its supporting IS schema. Typically, when using an XML schema definition as the source file, Designer prompts you for design-time decisions such as whether or not to expand complex types inline, how to handle element references, and the use of prefixes. However, when the source file is an e-form template, Designer makes the following design-time decisions:
*Complex types are expanded in-line.
*If the XML schema contains only one reference to a particular global element of complex type, Integration Server represents the element reference as a document defined line.
*Integration Server generates a separate IS document type for a named complex type only if the complex type is referenced or is derived from a referenced complex type.
*The IS document type uses the prefixes defined in the XML schema definition.
*Integration Server assigns the IS schema to a unique schema domain whose name is based on the path to and name of the e-form template.
*When you create the IS document type, make sure to select the root node. This will do the following:
*Ensure that the IS document type matches the e-form template. If you select a node that is not the root node, the resulting IS document type will not match the structure and content of the e-form template. At run-time, processes or services that receive instances of the e-form template will fail due to the mismatch.
*Ensure that the fields in the IS document type have the same properties as the corresponding elements in the e-form template. If you select a node that is not the root node, the properties for fields in the IS document type might not match the corresponding e-form template. For example, suppose that the e-form template specifies that a field allows null values and is required. If the root node is not selected, the corresponding field in the IS document type might disallow null values (Allow null = false) and indicate the field is optional (Required = false).
*For an IS document type created from a source, Designer displays the location of the source in the Source URI property. Designer also sets the Linked to source property to true which prevents any editing of the document type contents. To edit the document type contents, you first need to make the document type editable by breaking the link to the source. For information about allowing editing of elements derived from a source, see Allowing Editing of Derived Elements.
*To create an IS document type from an e-form template
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 one of the following:
Select...
To...
Adobe LiveCycle E-Form Template
Use an Adobe LiveCycle E-Form Template stored on the file system or My webMethods Server as the source for the document type.
Microsoft InfoPath E-Form Template
Use a Microsoft InfoPath E-Form Template stored on the file system or My webMethods Server as the source for the document type.
6. On the Select a Source Location panel, under Source location, select one of the following to specify the location of the e-form template:
Select...
To...
File/URL
Use an e-form template on a file system. Enter the path to and name of the e-form template or click Browse to navigate to and select the source file.
Click Next.
My webMethods Server
Use an Adobe LiveCycle E-Form Template or Microsoft InfoPath E-Form Template in the My webMethods Server content repository. Select the content repository that contains the e-form template and click Next.
7. On the Select Processing Options panel, under Content model compliance, select one of the following to indicate how strictly Integration Server represents content models from the XML Schema definition in the resulting IS document type.
Select...
To...
Strict
Generate the IS document type only if Integration Server can represent the content models defined in the XML Schema definition correctly. Document type generation fails if Integration Server cannot accurately represent the content models in the source XML Schema definition.
Currently, Integration Server does not support repeating model groups, nested model groups, or the any attribute. If you select strict compliance, Integration Server does not generate an IS document type from any XML schema definition that contains those items.
Lax
When possible, generate an IS document type that correctly represents the content models for the complex types defined in the XML schema definition. If Integration Server cannot correctly represent the content model in the XML Schema definition in the resulting IS document type, Integration Server generates the IS document type using a compliance mode of None.
When you select lax compliance, Integration Server will generate the IS document type even if the content models in the XML schema definition cannot be represented correctly.
None
Generate an IS document type that does not necessarily represent or maintain the content models in the source XML Schema definition.
When compliance is set to none, Integration Server generates IS document types the same way they were generated in Integration Server releases prior to version 8.2.
8. If you selected strict or lax compliance, next to Preserve text position, do one of the following to specify whether document types generated from complex types that allow mixed content will contain multiple *body fields to preserve the location of text in instance documents.
*Select the Preserve text position check box to indicate that the document type generated for a complex type that allows mixed content preserves the locations for text in instance documents. The resulting document type contains a *body field after each field and includes a leading *body field. In instance documents for this document type, Integration Server places text that appears after a field in the *body.
*Clear the Preserve text position check box to indicate that the document type generated for a complex type that allows mixed content does not preserve the locations for text in instance documents. The resulting document type contains a single *body field at the top of the document type. In instance documents for this document type, text data around fields is all placed in the same *body field.
9. If this document type will be used as the input or output signature of a service exposed as a web service and you want to enable streaming of MTOM attachment for elements of type base64Binary, select the Enable MTOM streaming for elements of type base64Binary check box.
For more information about streaming of MTOM attachments, see the Web Services Developer’s Guide
10. Click Next.
11. On the Select Root Node panel, under Select the root node, select the root node for the XML schema definition used in the e-form template.
The standard name for a root node is as follows:
*Adobe LiveCycle E-Form Template: xdp
*Microsoft InfoPath E-Form Template: myFields
Keep in mind that the e-form template developer can change the root node.
On the Select a Source Location panel, Designer displays the path to and name of the XML schema definition extracted from the e-form template in the File/URL field. Designer creates a set of temporary files containing the XML Schema definition in the workspace. Designer removes the files after creating the IS document type.
12. Under Element reference handling, select one of the following to determine how Integration Server handles references to global elements of complex type:
Select...
To...
Only generate document types for elements with multiple references
Instruct Integration Server to create a separate document type for a referenced element only when the XML Schema definition 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.
Always generate document types for referenced elements
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
Note:Integration Server always replaces an element reference to an element declaration of simple type with an inline field of type String.
13. Under Complex type handling, select one of the following to indicate how Integration Server handles references to named complex type definitions:
Select...
To...
Expand complex types inline
Use a document field defined in line to represent the content of a referenced complex type definition.
Generate document types for complex types
Create a separate IS document type to represent the content for a referenced complex type definition. The resulting IS document type for the root element represents the element of complex type using a document reference field. In turn, this document reference field refers to the IS document type created for the complex type definition.
Integration Server generates a separate IS document type for any types derived from the referenced complex types. For more information about derived types, see Derived Types and IS Document Types.
Note:Integration Server always represents an anonymous complex type using a document field defined inline.
14. If you selected Generate document types for complex types and you want to register each document type with the complex type definition from which it was created, select the Register document type with schema type check box.
Note:
If you want derived type support for document creation and validation, select the Register document types with schema type check box. For more information, see Registering Document Types with Their Schema Types.
15. If you want Integration Server to generate IS document types for all complex types in the XML Schema definition regardless of whether the types are referenced by elements or other type definitions, select the Generate document types for all complex types in XML Schema check box.
If you leave this check box cleared, Integration Server generates a separate IS document type for a complex type only if the complex type is referenced or is derived from a referenced complex type.
16. Click Finish.