<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=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:"Segoe UI Emoji";
        panose-1:2 11 5 2 4 2 4 2 2 3;}
@font-face
        {font-family:Georgia;
        panose-1:2 4 5 2 5 4 5 2 3 3;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
p.xmsonormal, li.xmsonormal, div.xmsonormal
        {mso-style-name:x_msonormal;
        margin:0in;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
span.EmailStyle24
        {mso-style-type:personal-reply;
        font-family:"Georgia",serif;
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
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="EN-US" link="blue" vlink="purple" style="word-wrap:break-word">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-family:"Georgia",serif">It may be something we want to leave for implementation check.  To the best of my knowledge, a regex to match a range of 1—366 (which fits with CCSDS Time code B) tends to be nontrivial to write
 and harder for mere mortals to read.  Regex does not really understand numeric ranges as it is more about pattern matching.  We could improve this with a relatively minor mod to the the regex for the day of year portion, i.e, [0-3][0-6][0-9] but this would
 allow the “patterns” 367, 367, 369 (but of course we would want to allow 359”) So still some minor checking.  This would maintain the leading zeroes for the earlier days of the year – ie., “001”, “002”, etc. If you really want to check for just 1..366 as a
 range, then we probably have a regex something along the lines of  (?:36[0-6]|3[0-5][0-9]|[12][0-9]{2}|[1-9]?[0-9]), but this would not allow “001;, just the ”range” of “1” to “366”.  And of course you would still have to further check that 366 is only used
 on those leap year occasions.    So perhaps either the relatively minor mod  (  [0-3][0-6][0-9]  )or just leave it as it is. 
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Georgia",serif"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Georgia",serif">Best regards,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Georgia",serif">-Erik<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Georgia",serif"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Georgia",serif"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Georgia",serif"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b>From:</b> SMWG <smwg-bounces@mailman.ccsds.org> <b>On Behalf Of
</b>Colin Haddow via SMWG<br>
<b>Sent:</b> Wednesday, March 1, 2023 5:42<br>
<b>To:</b> Marcin.Gnat@dlr.de; smwg@mailman.ccsds.org<br>
<b>Subject:</b> [EXTERNAL] Re: [cssm] Small question to WG<o:p></o:p></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<p class="MsoNormal">Hi Marcin,<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">                   I think basically it was one of the first things implemented when we were still getting to grips with XML and we've never revisited it. Probably makes sense to tighten up the definition when we do the 5 year review of
 the AED. I suspect something similiar a[plies to the CCSDS time code A defimition.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">Cheers for now<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">Colin (currently in Madrid airport waiting for connecting flight...)<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div id="ms-outlook-mobile-signature">
<p class="MsoNormal">Sent from <a href="https://urldefense.us/v3/__https:/aka.ms/AAb9ysg__;!!PvBDto6Hs4WbVuu7!LA8aY0GysUhdBE-foOVfALTzswzYmzTiiN-REieYAx-T5OAiXLors-Iz2EN3nR34YSYimAXDynqU-xKiwW-DOFZGAA$">
Outlook for Android</a><o:p></o:p></p>
</div>
<div class="MsoNormal" align="center" style="text-align:center">
<hr size="2" width="98%" align="center">
</div>
<div id="divRplyFwdMsg">
<p class="MsoNormal"><b><span style="color:black">From:</span></b><span style="color:black"> SMWG <<a href="mailto:smwg-bounces@mailman.ccsds.org">smwg-bounces@mailman.ccsds.org</a>> on behalf of Marcin Gnat via SMWG <<a href="mailto:smwg@mailman.ccsds.org">smwg@mailman.ccsds.org</a>><br>
<b>Sent:</b> Wednesday, March 1, 2023 12:19:34 PM<br>
<b>To:</b> <a href="mailto:smwg@mailman.ccsds.org">smwg@mailman.ccsds.org</a> <<a href="mailto:smwg@mailman.ccsds.org">smwg@mailman.ccsds.org</a>><br>
<b>Subject:</b> [cssm] Small question to WG</span> <o:p></o:p></p>
<div>
<p class="MsoNormal"> <o:p></o:p></p>
</div>
</div>
<div>
<div>
<p class="xmsonormal"><span lang="DE">Dear all,</span><o:p></o:p></p>
<p class="xmsonormal"><span lang="DE"> </span><o:p></o:p></p>
<p class="xmsonormal">DISCLEIMER: it’s not a initiation of any changes in any standards, but rather a question to smart community
<span style="font-family:"Segoe UI Emoji",sans-serif">😊</span><o:p></o:p></p>
<p class="xmsonormal"> <o:p></o:p></p>
<p class="xmsonormal">When working on implementation at DLR, one of my colleagues asked me, why our time code definition in schema allows any number ranges (i.e. for the DOY section everything between 000 and 999 is allowed)? Is it just to be handled by implementation
 (to watch out for DOY being between 001 and 365 or 366)? Any other thoughts?<o:p></o:p></p>
<p class="xmsonormal"> <o:p></o:p></p>
<p class="xmsonormal"> <o:p></o:p></p>
<p class="xmsonormal" style="text-autospace:none"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black;background:white">           
</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:blue;background:white"><</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:maroon;background:white">xsd:simpleType</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:red;background:white">
 name</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:blue;background:white">="</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black;background:white">CcsdsAsciiTimeCodeBType</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:blue;background:white">"></span><o:p></o:p></p>
<p class="xmsonormal" style="text-autospace:none"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black;background:white">                       
</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:blue;background:white"><</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:maroon;background:white">xsd:restriction</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:red;background:white">
 base</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:blue;background:white">="</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black;background:white">xsd:string</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:blue;background:white">"></span><o:p></o:p></p>
<p class="xmsonormal" style="text-autospace:none"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black;background:white">                                   
</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:blue;background:white"><</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:maroon;background:white">xsd:pattern</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:red;background:white">
 value</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:blue;background:white">="</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black;background:white">\d{4}-\d{3}T\d{2}:\d{2}:\d{2}(.(\d)+)?Z?</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:blue;background:white">"/></span><o:p></o:p></p>
<p class="xmsonormal" style="text-autospace:none"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black;background:white">                       
</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:blue;background:white"></</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:maroon;background:white">xsd:restriction</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:blue;background:white">></span><o:p></o:p></p>
<p class="xmsonormal" style="text-autospace:none"><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:black;background:white">           
</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:blue;background:white"></</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:maroon;background:white">xsd:simpleType</span><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:blue;background:white">></span><o:p></o:p></p>
<p class="xmsonormal"><span lang="DE"> </span><o:p></o:p></p>
<p class="xmsonormal"><span lang="DE">Cheers</span><o:p></o:p></p>
<p class="xmsonormal"><span lang="DE">Marcin</span><o:p></o:p></p>
</div>
</div>
</div>
</body>
</html>