The generateXMLSchema is a script that takes a given Repository component and item descriptor as arguments and produces an XML schema. For instructions on using this tools, see XML Schemas.

When you create an XML schema in support of a Web service, make sure that the same modules in the ATG platform are running now as those that will be running when the client calls the Web service.

For a list of Web services, associated Repository components and items descriptors, see the documentation for your ATG Web service.

You may find these two optional arguments helpful:

  • outputDirectory copies the resultant XML schema to the directory of your choosing.

  • mappingFile specifies a file that describes the RepositoryItem properties to include in the resultant XML schema.

Other Required Schemas

When a client deserializes a RepositoryItem, it uses the schema derived from the item descriptor to reconstruct each repository object and its properties in the appropriate data types. Depending on the makeup of the item descriptor, you may need to also generate a schema for related item descriptors.

Consider the Profile repository that uses the user item descriptor. There are two item descriptors, broker and investor, that are subtypes of user. If you were to use the updateProfile Web service call while the Relationship Management platform is running, user and all subtypes of it that are part of Relationship Management are accessible. When you call updateProfile, it’s unclear which version of user you want to call: user, investor or broker. In this case, you need to generate XML schemes for all three item descriptors.

In short, you need to generate an XML schema for all item descriptors used by RepositoryItems that are accessed by a Web service call and for any related (parent or child) item descriptors that are running when the call is made.

It is difficult to supply a general list of all item descriptors for which this added step applies because the contents of that list depend on many factors. When deciding if you need to create supplemental XML schemas for an item descriptor, consider the following:

Note: The previous discussion addresses item descriptors and their subtypes, meaning item descriptors that inherit from the parent class. This relationship should not be confused with that which item descriptors share with extensions of themselves, which are added by other modules. For example, the order item descriptor has one set of properties provided by the Consumer Commerce module. A second order item descriptor is supplied by Business Commerce and, when both modules are running, the order item descriptors are concatenated so that Business Commerce properties take precedence. Because all versions of order for the running module are combined into one, you need only one XML schema for the order item descriptor. When you create that XML schema for order, remember to do so while the same modules are running as will run when your Web service calls that item descriptor.

loading table of contents...