diff options
author | Alexis La Goutte <alexis.lagoutte@gmail.com> | 2013-01-20 18:32:23 +0000 |
---|---|---|
committer | Alexis La Goutte <alexis.lagoutte@gmail.com> | 2013-01-20 18:32:23 +0000 |
commit | 48cef7c61af8956238dc0710ea6ab32ed670bf68 (patch) | |
tree | 51e6881f42a43d0cfe87c20477e51317ac9c1b3d /fix/hfDecl.xsl | |
parent | 1a182e2a7957da396a11e109efd42bf2370e51b7 (diff) | |
download | wireshark-48cef7c61af8956238dc0710ea6ab32ed670bf68.tar.gz |
Enhance FIX generator
* Remove whitespace and tab
* Add information how to generate packet-fix.h (in top of packet-fix.h)
Regenerate packet-fix.h
svn path=/trunk/; revision=47178
Diffstat (limited to 'fix/hfDecl.xsl')
-rw-r--r-- | fix/hfDecl.xsl | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/fix/hfDecl.xsl b/fix/hfDecl.xsl index 8edd6b79df..b44d32e85c 100644 --- a/fix/hfDecl.xsl +++ b/fix/hfDecl.xsl @@ -8,27 +8,27 @@ <xsl:template match="/"> static fix_field fix_fields[] = { - <xsl:apply-templates/> - }; - </xsl:template> +<xsl:apply-templates/> + }; +</xsl:template> <xsl:template match="fields"> <xsl:for-each select="field"> - <xsl:sort select="@number" data-type="number"/> - <xsl:choose> - <xsl:when test="count( value ) != 0"> - <xsl:variable name="val_type" > - <xsl:choose> - <xsl:when test="@type='INT'">0</xsl:when> - <xsl:when test="@type='STRING'">1</xsl:when> - <xsl:otherwise>2</xsl:otherwise> - </xsl:choose> + <xsl:sort select="@number" data-type="number"/> + <xsl:choose> + <xsl:when test="count( value ) != 0"> + <xsl:variable name="val_type" > + <xsl:choose> + <xsl:when test="@type='INT'">0</xsl:when> + <xsl:when test="@type='STRING'">1</xsl:when> + <xsl:otherwise>2</xsl:otherwise> + </xsl:choose> </xsl:variable> - { <xsl:value-of select="@number"/>, -1, <xsl:copy-of select="$val_type" /> , <xsl:value-of select="@name"/>_val }, </xsl:when> - <xsl:otherwise> - { <xsl:value-of select="@number"/>, -1, 0, NULL }, /* <xsl:value-of select="@name"/> */ </xsl:otherwise> - </xsl:choose> + { <xsl:value-of select="@number"/>, -1, <xsl:copy-of select="$val_type" />, <xsl:value-of select="@name"/>_val },</xsl:when> + <xsl:otherwise> + { <xsl:value-of select="@number"/>, -1, 0, NULL }, /* <xsl:value-of select="@name"/> */</xsl:otherwise> + </xsl:choose> </xsl:for-each> -</xsl:template> +</xsl:template> </xsl:stylesheet> |