This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 113521 - Editor should accept xsl file with no default root node template
Summary: Editor should accept xsl file with no default root node template
Status: NEW
Alias: None
Product: soa
Classification: Unclassified
Component: XSLT (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: Sergey Lunegov
URL:
Keywords:
Depends on: 112816
Blocks:
  Show dependency tree
 
Reported: 2007-08-22 16:04 UTC by pvarghese
Modified: 2007-08-22 16:06 UTC (History)
2 users (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description pvarghese 2007-08-22 16:04:34 UTC
Netbeans version used: netbeans-trunk-nightly-200708061200-full.zip

The editor mandates that the newly created .xsl file should always have a default template.

The 'orderToCustTransform.xsl' when created has a default root template defined.

	<xsl:template match="/">
	</xsl:template>

Since the editor does not yet support template creation, manually changing this to have default templates as shown

    <xsl:template match="ns:Orders">
        <CustomerHistoryEntries xmlns="http://xml.netbeans.org/schema/custhistory"
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
            xsi:schemaLocation="http://xml.netbeans.org/schema/custhistory custhistory.xsd">
            <xsl:apply-templates/>
        </CustomerHistoryEntries>
    </xsl:template>

leads to error message in the design view 
"The XSLT file does not contain a root template element"

It is not mandatory that a .xsl file should contain a root template element.