[DFDL-WG] Why do occursCountKind=implicit and separatorSuppressionPolicy=never collide with unbounded?
Garriss Jr., James P.
jgarriss at mitre.org
Thu Jul 18 12:16:31 EDT 2013
The Content Type header can have multiple parameters, like so:
Content-Type: text/plain; charset=UTF-8; name=file.txt
I have defined the Content Type like so in DFDL:
<xsd:element name="ContentType" dfdl:initiator="Content-Type:%SP;" dfdl:terminator="%CR;%LF;">
<xsd:complexType>
<xsd:sequence dfdl:separator=";">
<xsd:element name="MimeType" type="xsd:string"/>
<xsd:element name="Parameter" type="ParameterType" minOccurs="0" maxOccurs="unbounded" dfdl:occursCountKind="implicit"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
When I run this against a Content Type with 0 or 1 parameters, everything is good. But when I run it with a Content Type header with two parameters, Daffodil throws this error:
2013-07-18 12:10:13:856 edu.illinois.ncsa.daffodil.compiler.ProcessorFactory Error[Schema Definition Error: separatorSuppressionPolicy='never' with occursCountKind='implicit' required bounded maxOccurs.
Schema context: element.Parameter. Location line 23 column 180 in
It seems that an element can't have separatorSuppressionPolicy='never' and occursCountKind='implicit' if it's unbounded.
Why is this an issue?
TIA
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.ogf.org/pipermail/dfdl-wg/attachments/20130718/76ebec41/attachment.html>
More information about the dfdl-wg
mailing list