Complex types in DR 11-0021

MURATA Makoto (FAMILY Given) eb2m-mrt at asahi-net.or.jp
Thu Sep 15 04:08:35 CEST 2011


FYI:

I used an XSLT stylesheet, F# program, and the diff command

XSLT is for xtracting element local names and complex 
type names.  This is used for generacing CSV files such as dml-main.csv

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    version="1.0">
    <xsl:output method="text"/>
    <xsl:template match="/ | *">
        <xsl:apply-templates select="*"></xsl:apply-templates>
    </xsl:template>
    <xsl:template match="xsd:element[@name and @type]">
        <xsl:value-of select="@name"/>,<xsl:choose>
            <xsl:when test="contains(@type, ':')"><xsl:value-of select="substring-after(@type, ':')"/></xsl:when>
            <xsl:otherwise><xsl:value-of select="@type"/></xsl:otherwise>
        </xsl:choose>
        <xsl:text><![CDATA[
]]></xsl:text>
    </xsl:template>
    
</xsl:stylesheet>

My simple F# program merely generates file name pairs.

let rec diffGenHelp e l =
-   match l with
-   | [] -> ()
-   | head::tail -> printfn "diff %s %s" e head; diffGenHelp e tail
- ;;

 let rec diffGen l =
-   match l with
-   | [] | [_] -> ()
-   | head::tail -> diffGenHelp head tail; diffGen tail
- ;;

And manually tweaked diff commands

diff --changed-group-format=__PREFIX__  dml-chart.csv dml-chartDrawing.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-chart.csv dml-diagram.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-chart.csv dml-lockedCanvas.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-chart.csv dml-main.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-chart.csv dml-picture.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-chart.csv dml-spreadsheetDrawing.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-chart.csv dml-wordprocessingDrawing.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-chartDrawing.csv dml-diagram.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-chartDrawing.csv dml-lockedCanvas.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-chartDrawing.csv dml-main.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-chartDrawing.csv dml-picture.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-chartDrawing.csv dml-spreadsheetDrawing.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-chartDrawing.csv dml-wordprocessingDrawing.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-diagram.csv dml-lockedCanvas.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-diagram.csv dml-main.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-diagram.csv dml-picture.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-diagram.csv dml-spreadsheetDrawing.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-diagram.csv dml-wordprocessingDrawing.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-lockedCanvas.csv dml-main.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-lockedCanvas.csv dml-picture.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-lockedCanvas.csv dml-spreadsheetDrawing.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-lockedCanvas.csv dml-wordprocessingDrawing.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-main.csv dml-picture.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-main.csv dml-spreadsheetDrawing.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-main.csv dml-wordprocessingDrawing.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-picture.csv dml-spreadsheetDrawing.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-picture.csv dml-wordprocessingDrawing.csv  | grep -vr '^__PREFIX__' 
 diff --changed-group-format=__PREFIX__  dml-spreadsheetDrawing.csv dml-wordprocessingDrawing.csv  | grep -vr '^__PREFIX__' 

Cheers,
Makoto


More information about the sc34wg4 mailing list