<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE score-partwise PUBLIC "-//Recordare//DTD MusicXML 4.0 Partwise//EN"
                                "http://www.musicxml.org/dtds/partwise.dtd">
<score-partwise version="4.0">
  <identification>
    <miscellaneous>
      <miscellaneous-field name="description">Multiple alternative endings.  The
          first alternative starts and ends at bar 2; the second continues until
          bar 5, the third, fifth, and seventh until bar 9, the fourth and sixth
          until bar 10, and the eighth is discontinued after one bar.

          In this test, the &lt;ending&gt; elements don't contain text except
          the one in bar 10, which holds ‘Foo’.</miscellaneous-field>
    </miscellaneous>
  </identification>
  <part-list>
    <score-part id="P1">
      <part-name>MusicXML Part</part-name>
    </score-part>
  </part-list>
  <!--=========================================================-->
  <part id="P1">
    <measure number="1">
      <attributes>
        <divisions>1</divisions>
        <key>
          <fifths>0</fifths>
          <mode>major</mode>
        </key>
        <time symbol="common">
          <beats>4</beats>
          <beat-type>4</beat-type>
        </time>
        <clef>
          <sign>G</sign>
          <line>2</line>
        </clef>
      </attributes>
      <note>
        <rest/>
        <duration>4</duration>
        <voice>1</voice>
      </note>
    </measure>
    <!--=======================================================-->
    <measure number="2">
      <barline location="left">
        <ending number="1" type="start"/>
      </barline>
      <note>
        <rest/>
        <duration>4</duration>
        <voice>1</voice>
      </note>
      <barline location="right">
        <bar-style>light-heavy</bar-style>
        <ending number="1" type="stop"/>
        <repeat direction="backward"/>
      </barline>
    </measure>
    <!--=======================================================-->
    <measure number="3">
      <barline location="left">
        <ending number="2" type="start"/>
      </barline>
      <note>
        <rest/>
        <duration>4</duration>
        <voice>1</voice>
      </note>
    </measure>
    <!--=======================================================-->
    <measure number="4">
      <note>
        <rest/>
        <duration>4</duration>
        <voice>1</voice>
      </note>
    </measure>
    <!--=======================================================-->
    <measure number="5">
      <note>
        <rest/>
        <duration>4</duration>
        <voice>1</voice>
      </note>
      <barline location="right">
        <bar-style>light-heavy</bar-style>
        <ending number="2" type="stop"/>
        <repeat direction="backward"/>
      </barline>
    </measure>
    <!--=======================================================-->
    <measure number="6">
      <barline location="left">
        <ending number="3, 5, 7" type="start"/>
      </barline>
      <note>
        <rest/>
        <duration>4</duration>
        <voice>1</voice>
      </note>
    </measure>
    <!--=======================================================-->
    <measure number="7">
      <note>
        <rest/>
        <duration>4</duration>
        <voice>1</voice>
      </note>
    </measure>
    <!--=======================================================-->
    <measure number="8">
      <note>
        <rest/>
        <duration>4</duration>
        <voice>1</voice>
      </note>
    </measure>
    <!--=======================================================-->
    <measure number="9">
      <note>
        <rest/>
        <duration>4</duration>
        <voice>1</voice>
      </note>
      <barline location="right">
        <bar-style>light-heavy</bar-style>
        <ending number="3, 5, 7" type="stop"/>
        <repeat direction="backward"/>
      </barline>
    </measure>
    <!--=======================================================-->
    <measure number="10">
      <barline location="left">
        <ending number="4, 6" type="start">Foo</ending>
      </barline>
      <note>
        <rest/>
        <duration>4</duration>
        <voice>1</voice>
      </note>
      <barline location="right">
        <bar-style>light-heavy</bar-style>
        <ending number="4, 6" type="stop"/>
        <repeat direction="backward"/>
      </barline>
    </measure>
    <!--=======================================================-->
    <measure number="11">
      <barline location="left">
        <ending number="8" type="start"/>
      </barline>
      <note>
        <rest/>
        <duration>4</duration>
        <voice>1</voice>
      </note>
      <barline location="right">
        <ending number="8" type="discontinue"/>
      </barline>
    </measure>
    <!--=======================================================-->
    <measure number="12">
      <note>
        <rest/>
        <duration>4</duration>
        <voice>1</voice>
      </note>
      <barline location="right">
        <bar-style>light-heavy</bar-style>
      </barline>
    </measure>
  </part>
  <!--=========================================================-->
</score-partwise>
