Service Development Help : Working with Document Types : Creating an IS Document Type : Creating a Document Type from a File in webMethods Content Service Platform
Creating a Document Type from a File in webMethods Content Service Platform
You can create an IS document type from any file in the webMethods Content Service Platform. The contents of the resulting IS document type consist of fields for the metadata that the Content Service Platform maintains about the file. Integration Server also adds a field named contentID. At run time, the contentID field contains a unique identifier for the instance of the content type.
To create an IS document type from a file in the webMethods Content Service Platform
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 a Source Type panel, select webMethods Content Service Platform and click Next.
6. In the From Repository list, select the content repository that contains the content type template from which you want to create a document type.
7. Click Next.
8. If you want to filter the contents of selected repository, type search criteria in the text box.
9. Select the content type from which you want to create a document type and click Next.
10. In the Description field, type a description for the IS document type. This is optional.
The description will appear in the Comment property for the IS document type. If you do not enter a description, the Comment property contains a message indicating the source of the IS document type.
11. Click Next.
12. 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.
13. 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.
14. 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
15. Click Next.
16. On the Select Root Node panel, under Select the root node, select the root node from which to create the IS document type.Designer displays the metadata fields from the content type. If the content type is associated with an e-form template, Designer displays those elements as well.
17. 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.
18. 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.
19. 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.
20. 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.
21. Click Finish.
Notes:
*When a content type in the Content Service Platform serves as the source, Designer creates a publishable IS document type. Designer adds the envelope (_env) field to the IS document type automatically. This field is a document reference to the pub:publish:envelope document type.
*If Integration Server is connected to a Broker at the time you create an IS document type from an content type in the Content Service Platform, the resulting IS document type will be publishable to the Broker and will have an associated Broker document type.
Copyright © 2017 Software AG, Darmstadt, Germany. (Innovation Release)

Product LogoContact Support   |   Community   |   Feedback