[DFDL-WG] Fw: Agenda for call 2007-02-13

Suman Kalia kalia at ca.ibm.com
Tue Feb 12 18:22:32 CST 2008


Action Item for   Vx+2 :      - assertions/discriminators and choice 
(Suman) 

Attached is an example of how discriminators can be used in DFDL to 
identify a particular branch within choice..

<?xml version="1.0" encoding="UTF-8"?>
<xsd:schema targetNamespace="http://www.example.org/choiceDiscriminators"
        xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:dfdl="
http://dataformat.org/"
        xmlns:tns="http://www.example.org/choiceDiscriminators">

        <xsd:element name="multiRecord" type="tns:MultiRecordType"></
xsd:element>

        <xsd:complexType name="MultiRecordType">
                <xsd:sequence>
                        <xsd:element name="recordType" type="xsd:string"
></xsd:element>
                        <!-- 
                                recordType precedes model group choice and 
its value determines
                                which branch of the choice is present. 
This is like a switch statement
                                of C or Java programming language. 
                        -->

                        <xsd:choice>
                                <xsd:sequence>
                                        <xsd:annotation>
                                                <xsd:appinfo source="
http://dataformat.org/">
                                                        <!--
 discriminator annotation on the model group sequence describes
                                                                the 
condition value to be checked for the recordType. The condition
                                                                could be a 
complex XPATH expression using XPATH functions to check for 
                                                                particular 
pattern of data for the condition (e.g. recordType 
                                                                value 
starting with xyz etc).
                                                        -->
                                                        <
dfdl:discriminator test="..\recordType='name'" />
                                                        <!--  identifies 
name record -->

                                                </xsd:appinfo>
                                        </xsd:annotation>

                                        <xsd:element name="firstName" type
="xsd:string" />
                                        <xsd:element name="lastName" type=
"xsd:string" />
                                </xsd:sequence>

                                <xsd:sequence>
                                        <xsd:annotation>
                                                <xsd:appinfo source="
http://dataformat.org/">
                                                        <
dfdl:discriminator test="..\recordType='addr'" />
                                                        <!--  identifies 
address record -->
                                                </xsd:appinfo>
                                        </xsd:annotation>

                                        <xsd:element name="streetAddr" 
type="xsd:string" />
                                        <xsd:element name="city" type=
"xsd:string" />
                                        <xsd:element name="state" type=
"xsd:string" />
                                        <xsd:element name="zip" type=
"xsd:string" />
                                </xsd:sequence>


                                <xsd:element name="otherElem" type=
"xsd:string">
                                        <xsd:annotation>
                                                <xsd:appinfo source="
http://dataformat.org/">
                                                        <
dfdl:discriminator test="..\recordType='oth" />
                                                        <!--  identifies 
other record -->
                                                </xsd:appinfo>
                                        </xsd:annotation>
                                </xsd:element>

                        </xsd:choice>

                </xsd:sequence>

        </xsd:complexType>

</xsd:schema>

Suman Kalia
IBM Toronto Lab
WebSphere Business Integration Application Connectivity Tools 
Tel : 905-413-3923  T/L  969-3923
Fax : 905-413-4850 T/L  969-4850
Internet ID : kalia at ca.ibm.com
----- Forwarded by Suman Kalia/Toronto/IBM on 02/12/2008 06:59 PM -----

"Mike Beckerle" <mbeckerle.dfdl at gmail.com> 
Sent by: dfdl-wg-bounces at ogf.org
02/12/2008 06:24 PM

To
<dfdl-wg at ogf.org>
cc

Subject
[DFDL-WG] Agenda for call 2007-02-13






 
Topics for this call include –
 
·         Content for OGF22 Meeting. – I need to know what features of our 
progress we want to highlight. The section about status and progress is 
where this content goes. Slides 37 through 51 of the OGF21 deck, which is 
here: http://forge.ogf.org/sf/go/doc15029?nav=1
 
·         Comments on Draft 031
 
·         Review of next tasks 
 
Old task list below for reference:
 
Planned (Roughly) 

vX+1 
- 2-level description (schema components) - including UML (Simon) 
- regular expressions for lengths (Alan) 
- valueCalc (Mike) 
- property precedence (Steve) 
- entities (Alan) 
- white space handling (Steve) 
  
vX+2 
- bring supplements up-to-date (Steve) 
- assertions/discriminators and choice (Suman) 
- how speculative parsing works (combining choice and variable-occurrence 
- currently these are separate) (TX person) 
- reordering the properties discussion (move representation earlier, 
improve flow of topics) (Alan) 

vX+3 
- escapeSchemes (Ian P) 
- string xml type (Ian P) 
- variables (Mike) 
- selectors (Suman) 
- improvements on property descriptions (All - split tbd) 
- envelopes and payloads (Steve) 

Extraneous to spec   
- develop Schema for DFDL xsd (Suman) 
- develop Schema for Schema DFDL Subset xsd (Suman) 
--
  dfdl-wg mailing list
  dfdl-wg at ogf.org
  http://www.ogf.org/mailman/listinfo/dfdl-wg
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.ogf.org/pipermail/dfdl-wg/attachments/20080212/03b9bc9e/attachment-0001.html 


More information about the dfdl-wg mailing list