Ah! The dfdl:encoding is the encoding of the separator (or initiator or 
terminator). Now I get it. Now it makes sense to specify encoding on 
xs:sequence. Thanks Mike.

/Roger

From: Beckerle, Mike <[email protected]>
Sent: Friday, April 10, 2020 10:09 AM
To: [email protected]
Subject: [EXT] Re: What is the rationale for requiring dfdl:encoding on the 
xs:sequence element?

All initiators, terminators, and separators are delimiters which are text which 
requires an encoding.

sequence, choice, and elements can have initiator and terminator.

sequences specifically can also have separators

This has nothing to do with the "content" of elements where the 
dfdl:representation property applies. Delimiters are outside of the boundaries 
of any "content" regions in DFDL-described data.

________________________________
From: Costello, Roger L. <[email protected]<mailto:[email protected]>>
Sent: Friday, April 10, 2020 9:53 AM
To: [email protected]<mailto:[email protected]> 
<[email protected]<mailto:[email protected]>>
Subject: Re: What is the rationale for requiring dfdl:encoding on the 
xs:sequence element?


Hi Mike,



  *   If the sequence has separators, initiators or terminators then encoding 
is required.



Why?



Elements have text, not sequences. So why is encoding required? I can 
understand requiring encoding if the sequence contains mixed content, but DFDL 
doesn't allow mixed content. You've stated a rule, but haven't explained why 
the rule exists in the first place.



/Roger





From: Beckerle, Mike <[email protected]<mailto:[email protected]>>
Sent: Friday, April 10, 2020 9:47 AM
To: [email protected]<mailto:[email protected]>
Subject: [EXT] Re: What is the rationale for requiring dfdl:encoding on the 
xs:sequence element?



If the sequence has separators, initiators or terminators then encoding is 
required. Otherwise it should not be.



There are a variety of bugs of this sort in Daffodil. They also tend to creep 
in unobserved. You fix an issue and reuse a piece of code. That code assumes 
encoding is defined. You don't need encoding, but having reused that code, now 
you end up requiring it also. Unless a regression test isolates this case 
exactly, the bug you just introduced about requiring encoding where it isn't 
needed goes undetected.



We don't have tests to insure that the property-requirements in Section 22 of 
the DFDL spec are strictly followed.







________________________________

From: Costello, Roger L. <[email protected]<mailto:[email protected]>>
Sent: Friday, April 10, 2020 9:33 AM
To: [email protected]<mailto:[email protected]> 
<[email protected]<mailto:[email protected]>>
Subject: What is the rationale for requiring dfdl:encoding on the xs:sequence 
element?



Hi Folks,

If I omit dfdl:encoding from the xs:sequence element, I get this error message:

[error] Schema Definition Error: Property encoding is not defined.

I struggle to understand the purpose of specifying an encoding on xs:sequence. 
Would you explain the rationale for this, please? As far as I can tell, the 
DFDL specification doesn't require encoding on xs:sequence.

/Roger

Reply via email to