Reputation: 2049
I am using Xalan. My input XML has default namespace. My XSL is huge and I dont want to prepend all selectors of XPATH with namespace alias. Is there api in Xalan with which I can set the default namespace so that I need not mention it in the XSL/XPATH.
Upvotes: 1
Views: 783
Reputation: 163352
No, the xpath-default-namespace attribute requires XSLT 2.0, which Xalan does not support.
If you are using Xalan-J, then there should be little difficulty switching to Saxon, which supports XSLT 2.0. This should give you the opportunity to make your XSLT code much less verbose if you don't want it to grow even huger.
Upvotes: 2