<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 14 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        mso-add-space:auto;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
p.MsoNormalCxSpFirst, li.MsoNormalCxSpFirst, div.MsoNormalCxSpFirst
        {mso-style-type:export-only;
        margin:0cm;
        margin-bottom:.0001pt;
        mso-add-space:auto;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
p.MsoNormalCxSpMiddle, li.MsoNormalCxSpMiddle, div.MsoNormalCxSpMiddle
        {mso-style-type:export-only;
        margin:0cm;
        margin-bottom:.0001pt;
        mso-add-space:auto;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
p.MsoNormalCxSpLast, li.MsoNormalCxSpLast, div.MsoNormalCxSpLast
        {mso-style-type:export-only;
        margin:0cm;
        margin-bottom:.0001pt;
        mso-add-space:auto;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
        {mso-style-priority:34;
        margin-top:0cm;
        margin-right:0cm;
        margin-bottom:0cm;
        margin-left:36.0pt;
        margin-bottom:.0001pt;
        mso-add-space:auto;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
p.MsoListParagraphCxSpFirst, li.MsoListParagraphCxSpFirst, div.MsoListParagraphCxSpFirst
        {mso-style-priority:34;
        mso-style-type:export-only;
        margin-top:0cm;
        margin-right:0cm;
        margin-bottom:0cm;
        margin-left:36.0pt;
        margin-bottom:.0001pt;
        mso-add-space:auto;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
p.MsoListParagraphCxSpMiddle, li.MsoListParagraphCxSpMiddle, div.MsoListParagraphCxSpMiddle
        {mso-style-priority:34;
        mso-style-type:export-only;
        margin-top:0cm;
        margin-right:0cm;
        margin-bottom:0cm;
        margin-left:36.0pt;
        margin-bottom:.0001pt;
        mso-add-space:auto;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
p.MsoListParagraphCxSpLast, li.MsoListParagraphCxSpLast, div.MsoListParagraphCxSpLast
        {mso-style-priority:34;
        mso-style-type:export-only;
        margin-top:0cm;
        margin-right:0cm;
        margin-bottom:0cm;
        margin-left:36.0pt;
        margin-bottom:.0001pt;
        mso-add-space:auto;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
span.EmailStyle18
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.EmailStyle19
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle20
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="FR-CH" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormalCxSpFirst"><font size="2" color="#1f497d" face="Calibri"><span style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span style="font-size:11.0pt;color:#1F497D">Hi Mark,<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">(I saw on the list archive that you answered my mail, but our mail server must have eaten the reply.)<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">> Am I the only one who doesn't like the Russian Doll?<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">>
<a href="http://www.oracle.com/technetwork/java/design-patterns-142138.html">http://www.oracle.com/technetwork/java/design-patterns-142138.html</a><o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">In defence of our developers, the schema is generated dynamically because the data structure is user-defined.<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">> Have your tried<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">> print $schema->template(PERL => "$yourns:contents");<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">I generated the template for the whole structure. For this extract it says<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> # is an unnamed complex<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> # is optional<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> contents =><o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> { # sequence of component<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> # is an unnamed complex<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> # occurs any number of times<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> component =><o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> [ { # choice of csRef<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> # is an unnamed complex<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> # is optional<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> csRef =><o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> { # sequence of csId, contentId<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> # is a xs:string<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> # Enum: cmis cmis-alfresco demo0 demo1 demo_no_logisitics<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> # demo_with_logisitics fld fld_zos jcr sp2010<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> # test.manual.enforce<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> csId => "cmis",<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> # is a xs:string<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle" style="margin-left:35.4pt;mso-add-space:auto"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"> contentId => "example", },<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">It does say that the choice is optional…<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">> So, you can say:<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">> component => [<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">> { cho_csRef => []<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">> ...
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">> }<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">I tried that, but it says:<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">error: no match for required block `cho_csRef' at node/contents/component<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">I tried with “csRef => {}”, and it said:<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">error: required value for element `csId' missing at node/contents/component/csRef<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">I tried with “csRef => undef,”, and it goes back to “no match …”.<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">Schema in attachment.<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D">Ciaran<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" color="#1f497d" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt;color:#1F497D"><o:p> </o:p></span></font></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormalCxSpMiddle"><b><font size="2" face="Tahoma"><span lang="EN-US" style="font-size:10.0pt;font-family:"Tahoma","sans-serif";font-weight:bold">From:</span></font></b><font size="2" face="Tahoma"><span lang="EN-US" style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">
DEIGNAN Ciaran [<a href="mailto:C.DEIGNAN@rsd.com">mailto:C.DEIGNAN@rsd.com</a>]
<br>
<b><span style="font-weight:bold">Sent:</span></b> jeudi 12 septembre 2013 14:40<br>
<b><span style="font-weight:bold">To:</span></b> <a href="mailto:xml-compile@lists.scsys.co.uk">
xml-compile@lists.scsys.co.uk</a><br>
<b><span style="font-weight:bold">Subject:</span></b> [Xml-compile] xs:choice question<o:p></o:p></span></font></p>
</div>
</div>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span lang="EN-GB" style="font-size:11.0pt"><o:p> </o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">Hi Mark and list,
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">I’m not sure if this is a XML::Compile question or just proof that I need training on XML.
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">I have a schema that contains a section like this:
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"><xs:element minOccurs="0" name="contents">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"><xs:complexType>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"><xs:sequence>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"><xs:element maxOccurs="unbounded" minOccurs="0" name="component">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"><xs:complexType>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"><xs:choice>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"><xs:element minOccurs="0" name="csRef">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"><xs:annotation>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"><xs:documentation>This element can be used to referenced when the content is already
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">stored in a content repository.
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">In the case of uploading the content, it must not be present.
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"></xs:documentation>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"></xs:annotation>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"><xs:complexType>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"><xs:sequence>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"><xs:element name="csId" type="csIdType"/>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"><xs:element name="contentId" type="xs:string"/>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"></xs:sequence>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"></xs:complexType>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"></xs:element>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"></xs:choice>
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">In perl I build a structure like this:
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"> contents => {
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"> component => [
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"> {
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"> csRef => { csId => 'fld', contentId => 'docid', },
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"> title => 'PerlTest',
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"> mimeType => 'text/plain',
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"> fileExtension => 'txt',
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"> lang => 'fr',
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"> },
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt"> ],
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">The above fragment will be converted to XML by XML::Compile::Schema. However if I don’t specify the csRef, it refuses to convert to XML, and gives me the error
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">error: no match for required block `cho_csRef' at node/contents/component
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">The schema does say minOccurs="0", so I don’t know why I have to provide it.
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">However the xs:choice does seem required, so I understand the error.
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">Is the schema just bad ?
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">Thanks for any pointers,
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">Ciaran Deignan
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpMiddle"><font size="2" face="Calibri"><span style="font-size:11.0pt">RSD Technical Support
<o:p></o:p></span></font></p>
<p class="MsoNormalCxSpLast"><font size="2" face="Calibri"><span style="font-size:11.0pt">
<o:p></o:p></span></font></p>
</div>
</body>
</html>