Hi Beatriz
-----Mensagem original-----
De: owner-xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
[mailto:owner-xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com] Em nome de
beatrizlangiano
Enviada: segunda-feira, 17 de Março de 2003 17:12
Para: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Cc: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Assunto: Re: [xsl] Moving elements of place
Hi Mike, this template exclude all elements child of
XMI.content, and I don't want this.
In this example, I want exlcude only
Foundation.Core.ModelElement.name.
The best way, has sugested by Mike, is to use the identity template and
change a bit on the those you want to be diferent:
<xsl:template match="@*|node()">
<xsl:copy>
<xsl:apply-templates select="@*|node()"/>
</xsl:copy>
</xsl:template>
<xsl:template match="XMI.content">
<xsl:copy>
<xsl:apply-templates select="@*|node()"/>
</xsl:copy>
<!-- now just select your node in a diferent mode -->
<xsl:apply-templates
select="Model_Management.Model/Foundation.Core.ModelEleme"
mode="NewCopy"/>
</xsl:template>
<!-- this will ignore all 'Foundation.Core.ModelEleme' nodes -->
<xsl:template match="Foundation.Core.ModelEleme"/>
<!-- this will do whatever you want it to do -->
<xsl:template match="Foundation.Core.ModelEleme" mode="NewCopy">
<!-- just reapply-templates to the corrent node -->
<xsl:apply-templates select="."/>
<!-- you also could use <xsl:copy-of select="."/> -->
</xsl:template>
Hope that this helps you
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list