Understanding the XML Schema
The XML schema defines the messages that you can use to access the FedEx services. You create a request that contains business data and other instructions and you send it to FedEx.
FedEx replies with a response that contains the data resulting from the instructions you sent in. The XML schema provides a means for defining the structure, content, and semantics of XML documents. An XML schema defines:
- Elements and attributes that can appear in a document
- Elements that are child elements
- Order and number of child elements
- Whether an element is empty or can include text
- Data types, default values and fixed values for elements and attributes
Some important facts about the XML schema:
- Elements that contain sub-elements or carry attributes have complex types.
- Elements that contain numbers (and strings, and dates, etc.), but do not contain any sub elements, have simple types. Some elements have attributes. Attributes always have simple types.
- Complex types in the instance document, and some of the simple types, are defined in the schema associated with a FedEx Web Service. Other simple types are defined as part of XML Schema's repertoire of built-in simple types.
- XML Schema built-in simple types are prefixed by "xs:", which is associated with the XML Schema namespace through the declaration xmlns:xs="http://www.w3.org/2001/ XMLSchema", displayed in the schema element.
- The same prefix, and the same association, are also part of the names of built-in simple types, e.g., xs:string. This association identifies the elements and simple types as belonging to the vocabulary of the XML Schema language, rather than the vocabulary of the schema author.