XML Schema Editor Features

XML Schema Editor has four main views to support creating, editing, and browsing XML Schemas:
  1. Content Outline View - work with XML Schema contents in the context of the complete structure.
  2. Design View - work on detailed level information for an object.
  3. Graph View - graphically browse the XML Schema structure.
  4. Source View - view the XML Schema source.
In addition, it also uses the property sheet as a secondary viewer for editing properties of the XML Schema.


Content Outline View

The Content Outline view displays the contents of the XML Schema as a tree structure. Right mouse two on an object in the tree will show you the list of actions that you can perform on a particular object.

On an XML Schema file object, you can:

On a Complex Type object, you can: On a Simple Type object, you can: Depending on the type of the simple type, the following actions might apply: On a Attribute Group object, you can: On a Content Model object, you can: On an Element or Global Element object, you can: On an Annotation object, you can: You can also use the Tree view to reorder the content model of a complex type, or to reorder the sequence of global elements, complex types, groups etc. in the XML Schema using drag and drop in the future.


Design View

When an object is selected in the Tree view, the Design view will show the detailed information for that selected object. You can use the Design view to edit the properties of a particular item, such as a complex type.

Element and Attribute Type

When you select an element, a global element, or an attribute, the Design view allows you to specify its type information. An element type can reference a complex type or a simple type. An attribute type must reference only simple types.

Anonymous Type

An element or attribute can define its type to be anonymous. An anonymous type can be useful if it is only referenced once and contain very few constraints. You do not have to explicitly named or referenced an anonymous type.

To specify that an element's type is anonymous, when the User-defined Simple Type or User-defined Complex Type is selected, choose the**anonymous** item in the combo-box. You can then start adding the content to the new anonymous type (simple or complex) that is added to the tree.

To specify that an attribute's type is anonymous, when User-defined Simple Type is selected, choose the**anonymous** item in the combo-box. You can then start updating the anonymous simple type that is added to the tree.


Property Sheet

Some schema elements have a lot of properties. For example, the schema element has properties such as attributeFormDefault and elementFormDefault. They are not shown directly in the Design View as they are considered less important to the design of the overall schema. If the user needs to edit these properties, they can use the Property Sheet to update the value.

To bring up the Property Sheet, select Perspective->Basic->Properties. When an object is selected in the Content Outline view, the additional properties for that object will be displayed in the Property Sheet and the user can update its value.


Graph View - (future release)

The Graph View provides a graphical view of the relationships between a complex type and its content. You can expand or collapse any branch by clicking on the + or - sign associated with a node.  You can also double click to position the Tree view to a particular element and go to the Design View for that element.


Source View

At any time, you can switch to the Source View to review the resultant XSD. When you select an object (say a complex type) in the Content Outline view, its content block in the source view will be marked by a marker in the vertical ruler on the left. You cannot edit the source from this view.


Menu Actions

The XML Schema Editor menu contains the following actions:
  1. Generate DTD. Generates a .dtd file for the XML Schema. Schema specific data that cannot be represented in a DTD will be skipped in the resultant DTD.
  2. Generate Java beans. Generates a set of Java beans to wrap the DOM.
  3. Generate HTML form. Generates a default HTML form (future release).
  4. Validate XSD. Determines whether the current state of the XSD is semantically valid based on the schema DTDs. Errors will be displayed into the Task View.