1. A computerized method for encoding an instance document representing a content description, the method comprising: determining a context node in the content description; obtaining a schema associated with the context node, the schema defining the required attributes, optional attributes, required elements, and optional elements for the context node, with the optional attributes and optional elements having an order; creating a required attributes section containing a value for each required attribute for the context node; creating an optional attributes section containing a value for each optional attribute for the context node that appears in the content description and further containing a header; creating a required elements section containing a value for each required element for the context node; and creating an optional elements section containing a value for each optional element for the context node that appears in the content description and further containing a header.