XMLPatterns.com

Home

Introduction
Pattern
History
Forms
Good Design
Journey

Patterns

Books

Links

About
Good XML Structural Design

The purpose of XML Structural Patterns are to help create document types that are designed well. The goal of a design can be thought of a balancing of forces. There are many competing forces that the designer of a document type must deal with simultaneously. In non-trivial problems, it is impossible for all of the forces to be eliminated completely, so compromises must be made.

These are some of the forces that the XML document designer must deal with:

Document Size

It is usually better to have short documents. Longer documents take up more disk space, take longer to process by machines and humans, and take longer to transmit across the network.

Ease of Authoring

Documents which are authored by people must be understandable to them. Extremely complex documents will cause authors to make mistakes, waste time, and get frustrated.

Ease of Processing

XML documents are ultimately processed by software at some point, and the document structure effects how difficult the processing software will be to write.

Flexibility

This is an indication of how the document instances written for a particular document type can differ. Some document types, such as HTML were meant to provide for a huge variety of documents to be written using them. For other systems, for examples, a payroll processing system, very strict rules about how the data is to be presented is needed.

Consistency

Consistency is important for documents to be usable. Inconsistencies lead to errors and misunderstandings.

Amount of Abstraction

The granularity and types of abstraction used in a document type will vary depending on the context. A date could be marked up as

<Date>12-10-2000</Date>

or

<Date> <Month>Dec</Month> <Day>10</Day> <Year>2000</Year> </Date>.

Which one is more appropriate depends on the situation where it is used.


Page 4 of 5
<<Pattern Forms| Contents | XML Design Patterns Journey>>
Visit our sponsors: (Interested in advertising on XMLPatterns.com?)