---
title: "11.9 XML Schema for Choreography"
chapter: "11 Choreography"
source: "OMG BPMN 2.0.2 — formal/2013-12-09"
pages: "363-365"
---

> 11 Choreography · páginas 363-365 · [índice](../README.md)


<a id="sec-11-9"></a>
## 11.9 XML Schema for Choreography


<a id="tab-11-9"></a>
**Table 11.9 – Choreography XML schema**

```xml
<xsd:element name="choreography" type="tChoreography" substitutionGroup="collaboration"/>
<xsd:complexType name="tChoreography">
    <xsd:complexContent>
        <xsd:extension base="tCollaboration">
            <xsd:sequence>
                <xsd:element ref="flowElement" minOccurs="0" maxOccurs="unbounded"/>
            </xsd:sequence>
        </xsd:extension>
    </xsd:complexContent>
</xsd:complexType>
```


<a id="tab-11-10"></a>
**Table 11.10 – GlobalChoreographyTask XML schema**

```xml
<xsd:element name="globalChoreographyTask" type="tGlobalChoreographyTask"
        substitutionGroup="choreography"/>
<xsd:complexType name="tGlobalChoreographyTask">
    <xsd:complexContent>
        <xsd:extension base="tChoreography">
            <xsd:attribute name="initiatingParticipantRef" type="xsd:QName"/>
        </xsd:extension>
    </xsd:complexContent>
</xsd:complexType>
```


<a id="tab-11-11"></a>
**Table 11.11 – ChoreographyActivity XML schema**

```xml
<xsd:element name="choreographyActivity" type="tChoreographyActivity"/>
<xsd:complexType name="tChoreographyActivity" abstract="true">
    <xsd:complexContent>
        <xsd:extension base="tFlowNode">
            <xsd:sequence>
                <xsd:element name="participantRef" type="xsd:QName" minOccurs="2"
                         maxOccurs="unbounded"/>
                <xsd:element name="correlationKey" minOccurs="0" maxOccurs="unbounded"/>
            </xsd:sequence>
            <xsd:attribute name="initiatingParticipantRef" type="xsd:QName" use="required"/>
            <xsd:attribute name="loopType" type="tChoreographyLoopType" default="None"/>
        </xsd:extension>
    </xsd:complexContent>
<xsd:complexType>
<xsd:simpleType name="tChoreographyLoopType">
    <xsd:restriction base="xsd:string">
        <xsd:enumeration value="None">
        <xsd:enumeration value="Standard">
        <xsd:enumeration value="MultiInstanceSequential">
        <xsd:enumeration value="MultiInstanceParallel">
    </xsd:restriction>
<xsd:simpleType>
```


<a id="tab-11-12"></a>
**Table 11.12 – ChoreographyTask XML schema**

```xml
<xsd:element name="choreographyTask" type="tChoreographyTask" substitutionGroup="flowElement"/>
<xsd:complexType name="tChoreographyTask">
    <xsd:complexContent>
        <xsd:extension base="tChoreographyActivity">
            <xsd:sequence>
                <xsd:element name="messageFlowRef" type="xsd:QName" minOccurs="1" maxOccurs="2"/>
            </xsd:sequence>
        </xsd:extension>
    </xsd:complexContent>
</xsd:complexType>
```


<a id="tab-11-13"></a>
**Table 11.13 – CallChoreography XML schema**

```xml
<xsd:element name="callChoreography" type="tCallChoreography" substitutionGroup="flowElement"/>
<xsd:complexType name="tCallChoreography">
    <xsd:complexContent>
        <xsd:extension base="tChoreographyActivity">
            <xsd:sequence>
                <xsd:element ref="participantAssociation" minOccurs="0" maxOccurs="unbounded"/>
            </xsd:sequence>
        <xsd:attribute name="calledChoreographyRef" type="xsd:QName" use="optional"/>
    </xsd:extension>
    </xsd:complexContent>
</xsd:complexType>
```


<a id="tab-11-14"></a>
**Table 11.14 – SubChoreography XML schema**

```xml
<xsd:element name="subChoreography" type="tSubChoreography" substitutionGroup="flowElement"/>
<xsd:complexType name="tSubChoreography">
    <xsd:complexContent>
        <xsd:extension base="tChoreographyActivity">
            <xsd:sequence>
                <xsd:element ref="flowElement" minOccurs="0" maxOccurs="unbounded"/>
                <xsd:element ref="artifact" minOccurs="0" maxOccurs="unbounded"/>
            </xsd:sequence>
        </xsd:extension>
    </xsd:complexContent>
</xsd:complexType>
```

