Home >Online Product Documentation >Table of Contents >Defining a simpleType in the Diagram View
This section describes the procedures for defining simpleTypes in the Diagram view. It covers the following topics:
Many of the editing features used in this section are described in Defining an XML Schema Using the Diagram Tab - Getting Started. You should familiarize yourself with that material if you have not done so already.
This topic provides the steps for defining an atomic simpleType in the Diagram view.
schema node The new simpleType appears in the diagram; its properties are displayed in the Properties window.
QuickEdit is a feature that combines commonly-performed editing operations, such as specifying a restriction for a simpleType. You can also perform this operation in a different way. See Specifying a Restriction for a simpleType - Manually.
simpleType node The Type Derivation dialog box appears.
The Type Derivation dialog box displays the W3C XML Schema, as well as any referenced XML Schemas.
The simpleType is updated with an element that identifies the restricted type:
In the lower half of the Properties window, Stylus Studio displays a section that allows you to specify facets - values that define the constraint on the range of values allowed by the base type.
Stylus Studio displays only those facets that are allowed for the base type you selected. For a description of each facet, see About Facet Types for simpleTypes.
This procedure describes how to specify a restriction for a simpleType manually. It is an alternative to the procedure described in Specifying a Restriction for a simpleType - QuickEdit.
simpleType node to display the shortcut menu.
The simpleType is updated with a restriction icon:
At the bottom of the Properties window, Stylus Studio displays a section that allows you to specify facets - values that define the constraint on the range of values provided by the base type.
Stylus Studio displays only those facets that are allowed for the base type you selected. For a description of each facet, see About Facet Types for simpleTypes.
The procedure for defining list and union simple types is similar:
simpleType as described in Defining a simpleType in the Diagram View.
simpleType and select Add > List or Add > Union).
simpleType's list or union. These types are restricted to annotations and other simpleTypes.
How you perform this last step depends on whether you are adding new or existing annotation or simpleType nodes to the list or union.
annotation or simpleType to the list or union, right click the list or union and select Add > Annotation or Add > SimpleType from the shortcut menu.annotation or simpleType to the list or union, drag the annotation or simpleType to the list or union, and drop it there, as shown in Figure 295, which shows SimpleType-6 being added to the union SimpleType-3.Notice that the pointer changes shape when you place it over an appropriate target node.