Using xalan:nodeset in Oxygen debugger

Having trouble installing Oxygen? Got a bug to report? Post it all here.
Webslung
Posts: 3
Joined: Wed Apr 03, 2013 6:14 am

Using xalan:nodeset in Oxygen debugger

Post by Webslung »

I'm working in Oxygen 14.2.

I'm trying to do the following and I can't seem to get it to work.

I want to run this stylesheet in the debugger view and I'm not getting any output. How do I ensure that I have access to the nodeset function with Xalan in my instance?

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xalan="http://xml.apache.org/xalan" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" exclude-result-prefixes="xhtml xalan" version="1.0" xmlns:xhtml="http://www.w3.org/1999/xhtml">

<xsl:variable name="group-1" select="'ABCDE'" />
<xsl:variable name="group-2" select="'FGHIJ'" />
<xsl:variable name="group-3" select="'MNOPQR'" />
<xsl:variable name="group-4" select="'STUVWXYZ'" />

<xsl:variable name="groups">
<groups>
<group><xsl:value-of select="$group-1"/></group>
<group><xsl:value-of select="$group-2"/></group>
<group><xsl:value-of select="$group-3"/></group>
<group><xsl:value-of select="$group-4"/></group>
</groups>
</xsl:variable>

<xsl:output indent="yes" method="xml"/>

<!-- Begin output -->
<xsl:template match="system-index-block">
<xsl:apply-templates select="calling-page/system-page[@current]"/>
</xsl:template>

<!-- Page output -->
<xsl:template match="system-page">

<xsl:call-template name="divs-depts-output" />

</xsl:template>

<!-- Begin divisions, departments output -->
<xsl:template name="divs-depts-output">

<xsl:for-each select="xalan:nodeset($groups)">
<xsl:value-of select="group" /><br />
</xsl:for-each>

</xsl:template>

</xsl:stylesheet>
Any help would be appreciated!
Webslung
Posts: 3
Joined: Wed Apr 03, 2013 6:14 am

Re: Using xalan:nodeset in Oxygen debugger

Post by Webslung »

I think I've figured out my problem. A couple of threads on here seem to have my answers.

1. How to get the Xalan extensions into Oxygen.
http://www.oxygenxml.com/forum/topic5103.html

That one seems to be how to get the appropriate .jar files in.

2. How to use a Tranformation Scenario in the Debugger:

http://www.oxygenxml.com/forum/topic2652.html

And THAT one explains how to use the scenario in the debugger. It would be AWESOME if I didn't have to set up a scenario to get this functionality in the debugger, but this solves an ages old problem for me. I hope this helps anyone in the future who's trying to get this functionality.
adrian
Posts: 2879
Joined: Tue May 17, 2005 4:01 pm

Re: Using xalan:nodeset in Oxygen debugger

Post by adrian »

Hi,

Actually you don't have to setup a transformation scenario to make extensions work in the XSLT debugger. While in the XSLT Debugger perspective you can simply press the Edit extensions toolbar button (on the first row, fifth button from the right) and add the extensions there.

Having said that, we generally recommend using transformation scenarios even for debugging. This way you can easily switch between debugging sessions/environments when necessary (debug another scenario) and you won't have to manually reconfigure the debugging environment each time.

Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
Post Reply