2.3.6.1.3.7 contentTypeSchema

The attributes and child elements of this element collectively specify a schema for the custom XML data item that specifies properties of the content type associated with the document. Each child of this element is an xsd:schema (section 2.3.6.1.3.6) element (as specified by [W3C-XSD]) that specifies one or more elements that appear in the custom XML data item. These xsd:schema elements are decorated with attributes from the http://schemas.microsoft.com/office/2006/metadata/properties/metaAttributes namespace as specified in section 2.3.6.1.3.5.

This element MUST contain an xsd:schema child element that has the ma:root Root (DummyContentTypeElement.DummyContentType@root (section 2.3.6.1.3.5)) attribute with value true. This xsd:schema specifies the structure of the root element of this Custom XML Data Storage item. This xsd:schema MUST have its targetNamespace attribute set to http://schemas.microsoft.com/office/2006/metadata/properties. It MUST declare and import any namespaces used by its child elements that are specified by other xsd:schema child elements. This xsd:schema element MUST have a ma:fieldsID Field IDs Hash (DummyContentTypeElement.DummyContentType@fieldsID (section 2.3.6.1.3.5)) attribute.

Additionally, this xsd:schema element MUST declare an element called properties with the following structure. The child elements of the xsd:all are not shown, but are instead specified following this XML markup.

 <xsd:element name="properties">
   <xsd:complexType>
     <xsd:sequence>
       <xsd:element name="documentManagement">
         <xsd:complexType>
           <xsd:all>
             ...
           </xsd:all>
         </xsd:complexType>
       </xsd:element>
     </xsd:sequence>
   </xsd:complexType>
 </xsd:element>

In the following description, the term "content type" refers specifically to the root element of the Content Type Definition Type as specified in Collaborative Application Markup Language (CAML) Structure ([MS-WSSCAML] section 2.4.1.1).

Let the term "fields" denote the list of all Field elements that are the fields used in the content type, as specified in Collaborative Application Markup Language (CAML) Structure ([MS-WSSCAML] section 2.3.2.6). Furthermore, let the term "filtered fields" denote the list of all filtered fields to be those Field elements from the fields that satisfy all of the following conditions (the quotes are not included):

  • The value of the Type attribute is not "Computed", "Calculated", "WorkflowStatus", "TaxonomyFieldType", or "TaxonomyFieldTypeMulti".

  • The value of the Name attribute is not "Modified_x0020_By", "Created_x0020_By", "Modified", "Created", or "FileLeafRef".

  • The value of the StaticName attribute is not "Title", "Subject", "_Author", "Keywords", "_Comments", "_Category", "Slides", "ContentType", or "Status".

The xsd:all element from the structure described previously MUST contain an xsd:element element for each Field element in the filtered fields set. This xsd:element MUST have a ref attribute. The value of the ref attribute MUST be a qualified reference to a type whose name is the value of the StaticName attribute of the Field element, and which resides in the namespace identified by the SourceID attribute of the Field element. Furthermore, if the Required attribute is not present on the Field element, or if the attribute is present but its value is not true, or if the value of the Type attribute is "MultiChoice" or "LookupMulti", then a minOccurs attribute with value of 0 MUST be present on the xsd:element element.

For each unique string that appears as the value of the SourceID attributes on any Field element in fields, the contentTypeSchema element MUST contain an xsd:schema child whose targetNamespace attribute has that same value. Each xsd:schema MUST contain one xsd:element element for each Field whose SourceID attribute is the same as the targetNamespace of the xsd:schema.

Each xsd:element element MUST have a Name attribute whose value is the value of the StaticName attribute on the corresponding Field element. Each xsd:element element MUST have a ma:index Index (DummyContentTypeElement.DummyContentType@index (section 2.3.6.1.3.5)) attribute whose value is the number of Field elements that appear before the corresponding Field element within the Fields element in the content type. If the Required attribute is not present on the corresponding Field element, or if the attribute is present but its value is not true, or if the value of the Type attribute is "MultiChoice" or "LookupMulti", a nullable attribute ([W3C-XSD]) with value of true MUST be present on the xsd:element element.

The following attributes can appear on each xsd:element element:

  • ma:displayName Display Name (DummyContentTypeElement.DummyContentType@displayName (section 2.3.6.1.3.5))

  • ma:decimals Decimals (DummyContentTypeElement.DummyContentType@decimals (section 2.3.6.1.3.5))

  • ma:default Default (DummyContentTypeElement.DummyContentType@default (section 2.3.6.1.3.5))

  • ma:description Description (DummyContentTypeElement.DummyContentType@description (section 2.3.6.1.3.5)); ma:format Format (DummyContentTypeElement.DummyContentType@format (section 2.3.6.1.3.5))

  • ma:hidden Hidden (DummyContentTypeElement.DummyContentType@hidden (section 2.3.6.1.3.5))

  • ma:LCID LCID (DummyContentTypeElement.DummyContentType@LCID (section 2.3.6.1.3.5))

  • ma:list List (DummyContentTypeElement.DummyContentType@list (section 2.3.6.1.3.5))

  • ma:internalName Internal Name (DummyContentTypeElement.DummyContentType@internalName (section 2.3.6.1.3.5))

  • ma:readOnly Read Only (DummyContentTypeElement.DummyContentType@readOnly (section 2.3.6.1.3.5))

  • ma:showField Show Field (DummyContentTypeElement.DummyContentType@showField (section 2.3.6.1.3.5))

  • ma:percentage Percentage (DummyContentTypeElement.DummyContentType@percentage (section 2.3.6.1.3.5))

  • ma:web Web (DummyContentTypeElement.DummyContentType@web (section 2.3.6.1.3.5))

  • ma:requiredMultiChoice Required Multiple Choice (DummyContentTypeElement.DummyContentType@requiredMultiChoice (section 2.3.6.1.3.5))

The contentTypeSchema MUST have an xsd:schema child element whose targetNamespace attribute has the value "http://schemas.openxmlformats.org/package/2006/metadata/core-properties".

Child element: schema (section 2.3.6.1.3.6)

Attributes:

contentTypeDescription : MUST be the same value as the Description attribute of the ContentType element (as specified in Collaborative Application Markup Language (CAML) Structure ([MS-WSSCAML] section 2.4.1.1) for the content type associated with the document.

contentTypeID : Identifies the content type associated with the document.

contentTypeName : MUST be the same value as the Name attribute of the ContentType element as specified in Collaborative Application Markup Language (CAML) Structure ([MS-WSSCAML] section 2.4.1.1) for the content type associated with the document.

contentTypeScope : MUST be empty and MUST be ignored.

contentTypeVersion : MUST be the same value as the Version attribute of the ContentType element as specified in Collaborative Application Markup Language (CAML) Structure ([MS-WSSCAML] section 2.4.1.1) for the content type associated with the document.

versionID : Specifies the string hash used to determine if the definition of the content type associated with the document has changed since the last time the content type was applied to the document. The value MUST be computed as an MD5 hash (as specified in [RFC1321]) of the substring that represents the ContentType element (beginning with "<ContentType" and ending with "</ContentType>", both strings included) within the SOAP result of the GetListContentType web service request ([MS-LISTSWS] section 3.1.4.17).

<xsd:complexType name="CT_ContentTypeSchema">

  <xsd:sequence>

    <xsd:element ref="xsd:schema" maxOccurs="unbounded"/>

  </xsd:sequence>

  <xsd:attribute name="contentTypeName" type="xsd:string" />

  <xsd:attribute name="contentTypeID" type="ContentTypeId" />

  <xsd:attribute name="contentTypeVersion" type="IntNonNegative" />

  <xsd:attribute name="contentTypeDescription" type="xsd:string" />

  <xsd:attribute name="contentTypeScope" type="xsd:string" />

  <xsd:attribute name="versionID" type="xsd:string" />

</xsd:complexType>