Stylus Studio XML Editor

Table of contents

Appendices

E.1 DTD

DTD

A DTD may be used as the schema language for WSDL. It may not be embedded; it must be imported. A namespace must be assigned. DTD types appear in the {element declarations} property of [The Definitions Component] and may be referenced from the wsdl:input, wsdl:output and wsdl:fault elements using the element attribute information item.

The prefix, dtd, used throughout the following is mapped to the namespace URI http://www.example.org/dtd/.

The dtd:import element information item references an external Document Type Definition, and has the following infoset properties:

  • A [local name] of import.

  • A [namespace name] of "http://www.example.org/dtd".

  • One or two attribute information items, as follows:

    • A REQUIRED namespace attribute information item as described below.

    • An OPTIONAL location attribute information item as described below.

namespace attribute information item[top]

namespace attribute information item

The namespace attribute information item sets the namespace to be used with all imported element definitions described in the DTD. It has the following infoset properties:

  • A [local name] of namespace.

  • A [namespace name] which has no value.

The type of the namespace attribute information item is xs:anyURI.

The WSDL author should ensure that a prefix is associated with the namespace at the proper scope (probably document scope).

location attribute information item[top]

location attribute information item

The location attribute information item, if present, provides a hint to the processor as to where the DTD may be located. Caching and cataloging technologies may provide better information than this hint. The location attribute information item has the following infoset properties:

  • A [local name] of location.

  • A [namespace name] which has no value.

The type of the location attribute information item is xs:anyURI.

References to Element Definitions[top]

References to Element Definitions

The element attribute information item MUST be used when referring to an element definition (<!ELEMENT>) from a Message Reference component; referring to an element definition from a Interface Fault component is similar. The value of the element definition MUST correspond to the content of the namespace attribute information item of the dtd:import element information item. The local name part must correspond to an element defined in the DTD.

Note that this pattern does not attempt to make DTDs namespace-aware. It applies namespaces externally, in the import phase.