Partitioning types

When data objects of different types appear in the same place in the data, the types must be distinguishable. This means that the data needs to be distinguishable by their definitions in the schema.

When the data object at any given point in the data may belong to any of a number of different types, there must be some way to tell the difference between them. To do this, you create a type and define a mutually exclusive subtype for each data object that may appear in the same place in the data. Once the subtypes are created, the subtypes also need to be distinguishable. Subtypes are distinguishable based on a value in the data or in the syntax of the different types.