Sha256: 7ed12f378fc44b585bb5370dc87b952535a478744592e9e842fe0d68342ce5a7

Contents?: true

Size: 955 Bytes

Versions: 15

Compression:

Stored size: 955 Bytes

Contents

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:fo="http://www.w3.org/1999/XSL/Format">
<xsl:variable name="target"><xsl:choose>
	<xsl:when test="/ONIXMessage">short</xsl:when>
	<xsl:otherwise>reference</xsl:otherwise>
</xsl:choose></xsl:variable>
<xsl:output method="xml" doctype-system="http://www.editeur.org/onix/2.1/reference/onix-international.dtd"/>
<xsl:template match="*">
	<xsl:variable name="target-name">
		<xsl:choose>
			<xsl:when test="$target='short'"><xsl:value-of select="@shortname"/></xsl:when>
			<xsl:otherwise><xsl:value-of select="@refname"/></xsl:otherwise>
		</xsl:choose>
	</xsl:variable>
 <xsl:element name="{$target-name}">
  <xsl:copy-of select="@*[not(name()='refname' or name()='shortname')]"/>
  <xsl:apply-templates select="*|text()"/>
 </xsl:element>
</xsl:template>
<xsl:template match="text()">
 <xsl:copy/>
</xsl:template>
</xsl:stylesheet>

Version data entries

15 entries across 15 versions & 2 rubygems

Version Path
onix-0.8.4 support/switch-onix-2.1-short-to-reference.xsl
milkfarm-onix-0.8.6 support/switch-onix-2.1-short-to-reference.xsl
milkfarm-onix-0.8.5 support/switch-onix-2.1-short-to-reference.xsl
onix-0.8.3 support/switch-onix-2.1-short-to-reference.xsl
milkfarm-onix-0.8.3 support/switch-onix-2.1-short-to-reference.xsl
onix-0.8.2 support/switch-onix-2.1-short-to-reference.xsl
milkfarm-onix-0.7.7 support/switch-onix-2.1-short-to-reference.xsl
onix-0.8.1 support/switch-onix-2.1-short-to-reference.xsl
onix-0.8.0 support/switch-onix-2.1-short-to-reference.xsl
onix-0.7.8 support/switch-onix-2.1-short-to-reference.xsl
onix-0.7.7 support/switch-onix-2.1-short-to-reference.xsl
onix-0.7.6 support/switch-onix-2.1-short-to-reference.xsl
onix-0.7.5 support/switch-onix-2.1-short-to-reference.xsl
onix-0.7.4 support/switch-onix-2.1-short-to-reference.xsl
onix-0.7.3 support/switch-onix-2.1-short-to-reference.xsl