<html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body>
    <p>If I recall... the file is evaluated for the current context,
      resolving all the conditions based on the context item (eprint),
      and ending up with a set of stages, containing components,
      containing fields.</p>
    <p>So long as that happens it'll work fine. However if you've
      decided to put the logic at a higher level, that's fine. Just be
      careful to make sure when you make a change you apply it to all
      the relevant places it repeats that element. <br>
    </p>
    <p><br>
    </p>
    <div class="moz-cite-prefix">On 13/05/2022 14:40, Laurent Cloarec
      via Eprints-tech wrote:<br>
    </div>
    <blockquote type="cite" cite="mid:3737d0f1-3609-28c9-6f18-f98289eb7d5c@ut-capitole.fr">
      
      <div style="padding-bottom: 10px; padding-top: 5px;">
        <div style="padding:12px; border:1px solid #8D3970;
          background-color:#F7F9FA; color:#8D3970; font-size:14px;
          line-height:22px; font-family: Calibri, Arial, Helvetica,
          sans-serif;">
          <strong>CAUTION:</strong> This e-mail originated outside the
          University of Southampton.
        </div>
      </div>
      <div>Hi everybody!<br>
        <br>
        <br>
        The &quot;core&quot; stage of the cfg/workflows/eprint/default.xml file
        for our repository had slowly become a &quot;mess&quot; (or, if you prefer
        a gastronomic metaphor, some kind of &quot;plate of spaghetti&quot;!),
        each time harder to maintain, with its huge amount of nested
        tests, loops, etc...<br>
        <br>
        For instance, I've just figured out that two contradictory
        logical tests where nested one into the other!<br>
        <br>
        So I would like to reorder it, and the first idea that comes to
        me is to use the following EPC tags, according to the type of
        item, somehow like this:<br>
        <blockquote type="cite">
          <pre>&lt;epc:choose&gt;</pre>
          <pre>&nbsp;&nbsp;&nbsp; &lt;epc:when test=&quot;type ='item_type_x'&quot;&gt;</pre>
          <pre>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; ...</pre>
          <pre>&nbsp;&nbsp;&nbsp; &lt;/epc:when&gt;</pre>
          <pre>&nbsp;&nbsp;&nbsp; &lt;epc:when test=&quot;type ='item_type_y'&quot;&gt;</pre>
          <pre>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; ...</pre>
          <pre>&nbsp;&nbsp;&nbsp; &lt;/epc:when&gt;</pre>
          <pre>&nbsp;&nbsp;&nbsp; &lt;epc:when test=&quot;type ='item_type_z'&quot;&gt;</pre>
          <pre>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; ...</pre>
          <pre>&nbsp;&nbsp;&nbsp; &lt;/epc:when&gt;</pre>
          <pre>&nbsp;&nbsp;&nbsp; &lt;epc:otherwise&gt;</pre>
          <pre>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; ...</pre>
          <pre>&nbsp;&nbsp;&nbsp; &lt;/epc:otherwise&gt;</pre>
          <pre>&lt;/epc:choose&gt;</pre>
        </blockquote>
        where the &quot;...&quot; dots would be replaced by the complete list of
        every &quot;component&quot; necessary for the given item type, with the
        required values tests.<br>
        <br>
        But my question comes around the fact to wonder if it's a good
        idea, or if it is mandatory to follow the commonly ordered flow
        of all possible components, whatever the item type may be (tests
        would determine their presence or not).<br>
        <br>
        <br>
        Thank you in advance for any &quot;authorized&quot; answer, and best
        regards...<br>
        --<br>
        Laurent Cloarec<br>
        Service Commun de la Documentation - Service du Numérique
        Documentaire<br>
        Université Toulouse 1 Capitole<br>
        tél. : (+33)(0)5.34.45.61.23 </div>
      <br>
      <fieldset class="moz-mime-attachment-header"></fieldset>
      <pre class="moz-quote-pre" wrap="">*** Options: <a class="moz-txt-link-freetext" href="http://mailman.ecs.soton.ac.uk/mailman/listinfo/eprints-tech">http://mailman.ecs.soton.ac.uk/mailman/listinfo/eprints-tech</a>
*** Archive: <a class="moz-txt-link-freetext" href="https://eur03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.eprints.org%2Ftech.php%2F&amp;data=05%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C6416fce84052496d475e08da34f27695%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637880513209614881%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&amp;sdata=gG22mrWf7fGq%2FIyAB3q%2BV7hF8NwjYyNJ5Whqd4yLR28%3D&amp;reserved=0" originalSrc="http://www.eprints.org/tech.php/" shash="byuexcihlKWd6cF1lMfCZoSykfE/Xw7KgxPx+SFxoMjBVSAcv175OwevjXQPw4wpXEru6xA7rvCFvro5Z0IaqeHPKee+WjYm0ULJ7egVLpSs+VCXJ/R6AOiOogh+hFuLugHXu1Wo6X5uPGC1AUvAQPp8WXBIXa5n6p71egABJeA=">http://www.eprints.org/tech.php/</a>
*** EPrints community wiki: <a class="moz-txt-link-freetext" href="https://eur03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwiki.eprints.org%2F&amp;data=05%7C01%7Ceprints-tech%40ecs.soton.ac.uk%7C6416fce84052496d475e08da34f27695%7C4a5378f929f44d3ebe89669d03ada9d8%7C0%7C0%7C637880513209614881%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&amp;sdata=%2BDREPqrCGkxgOHdB4S2j3w0AXxd%2F2H0qUfBwhlsnk6s%3D&amp;reserved=0" originalSrc="http://wiki.eprints.org/" shash="b4TNj5J0sGtBOROaJwMnEQNrZ8GNA1KoemTQvJgPM3ATWlcZ8bYzxYtZNk3umxG9CCcvIgUlzq15n25vdTijKjwEQUb/Qc2DqJiwXLBE12dG5kt7hGhWUFvs6/E6bD4IkZFEXmLZ7fG5VxH9aFErSjbRH62MmOZ6qHvp3z6T8z8=">http://wiki.eprints.org/</a></pre>
    </blockquote>
    <pre class="moz-signature" cols="72">-- 
Christopher Gutteridge <a class="moz-txt-link-rfc2396E" href="mailto:totl@soton.ac.uk">&lt;totl@soton.ac.uk&gt;</a> 
You should read our team blog at <a class="moz-txt-link-freetext" href="http://blog.soton.ac.uk/webteam/">http://blog.soton.ac.uk/webteam/</a>
(I live near Highfield Campus, so in person, outdoor and socially distanced meetings are an option)</pre>
  </body>
</html>