The DFDL 1.0 spec implies the behaviour
where you get:
<a>password</a>
<b>f82+</b>
followed by a processing error. There
is no special casing of the last element in the group.
Changing the model to the following
achieves the desired infoset:
<sequence dfdl:separator="=" dfdl:separatorPosition="infix">
<element name="a" type="xs:string"/>
<sequence dfdl:separator="">
<element name="b" type="xs:string"/>
</sequence>
</sequence>
Regards
Steve Hanson
Architect, IBM Data Format Description Language (DFDL)
Co-Chair, OGF
DFDL Working Group
IBM SWG, Hursley, UK
smh@uk.ibm.com
tel:+44-1962-815848
From:
Tim Kimber/UK/IBM@IBMGB
To:
dfdl-wg@ogf.org,
Date:
19/06/2013 09:37
Subject:
Re: [DFDL-WG]
clarification on when escape characters are needed
Sent by:
dfdl-wg-bounces@ogf.org
In the IBM implementation we have taken
the view that the separator defines the format for all of the group's content.
That means that all separators are counted as being significant, even if
they occur within the content region of the final group member.
I agree that other interpretations are possible - the MRM parser in earlier
versions of WebSphere Message Broker takes an infix separator out of scope
when it encounters the final declared child of a group.
I intend to address this point when I write up the rules for matching string
literals and delimiters.
regards,
Tim Kimber, DFDL Team,
Hursley, UK
Internet: kimbert@uk.ibm.com
Tel. 01962-816742
Internal tel. 37246742
From: Mike
Beckerle <mbeckerle.dfdl@gmail.com>
To: dfdl-wg@ogf.org,
Date: 19/06/2013
03:52
Subject: [DFDL-WG]
clarification on when escape characters are needed
Sent by: dfdl-wg-bounces@ogf.org
Suppose I have a sequence. It has an infix separator which is "=".
<sequence dfdl:separator="=" dfdl:separatorPosition="infix">
<element name="a" type="xs:string"/>
<element name="b" type="xs:string"/>
</sequence>
Now, consider this data:
password=f82+=7&%q
I want
<a>password</a>
<b>f82+=7&%q</b>
Notice how the b element contains an '=' which was not escaped in any way
in the sequence. Element b is statically known to be last, the separator
is infix; hence, things are unambiguous even if there is no escaping.
However, there is an alternative interpretation, which is that the above
data should fail, because it produces <a>password</a><b>f82+</b>
but then does not find the expected stuff next. Rather it finds the '=7&%q'
data. In other words, the sequence separator divides the sequence content
into 3 content regions, but there aren't 3 things to consume those, so
it is a processing error.
Which is correct?
--
Mike Beckerle | OGF DFDL Workgroup Co-Chair | Tresys Technology | www.tresys.com
--
dfdl-wg mailing list
dfdl-wg@ogf.org
https://www.ogf.org/mailman/listinfo/dfdl-wg
Unless stated otherwise above:
IBM United Kingdom Limited - Registered in England and Wales with number
741598.
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6
3AU--
dfdl-wg mailing list
dfdl-wg@ogf.org
https://www.ogf.org/mailman/listinfo/dfdl-wg
Unless stated otherwise above:
IBM United Kingdom Limited - Registered in England and Wales with number
741598.
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6
3AU