• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

XML Namespace

 
Ranch Hand
Posts: 395
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,
I want to know when I use my own namespace and use the prefix in my XML document, How does my XML Parser or XSL Engine interpret the xmlns:myNS="http://www.myURL.com".
For Example When i use XSL namespace i.e xmlns:xsl="http://www.w3.org/1999/xsl/Transform and I use XSL tags which work on my XML file.
Does this mean that my parser connects to the above URL?
Or My parser already has the XSL tag's functionality defined?
How does this work for Userdefined namespace like i said before.
Thanks.

------------------
L Goundalkar
lggoundalkar@hotmail.com
Sun Certified Programmer for Java 2 Platform
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The namespace is just used to create a unique name, however, some applications might have certain namespaces built in. For example in SOAP, these namespaces may be checked by sender or receiver.
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
Bill
------------------
author of:
 
L Goundalkar
Ranch Hand
Posts: 395
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
So you mean to say the Schema, XSL Transform, XSL Formatting Objects, SOAP all these namespace tag declarations are built in the Parsers?
If so what will happend to user defined namespace.?
How to define the functionality of user defined tags.?
BTW where can i get the list of namespaces built in side my parser or xsl engine.
Thanks
------------------
L Goundalkar
lggoundalkar@hotmail.com
Sun Certified Programmer for Java 2 Platform
 
William Brogden
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
NOT built into the parsers, the parsers just recognize and store the namespaces. It is the application that uses the parsed data that may know and care about the namespace.
Just looking through the JAXP documentation I don't see any method to discover all the namespaces that are in use in a Document (although you would think that would be simple).
Bill
 
L Goundalkar
Ranch Hand
Posts: 395
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi William,
If it is so, then who is parsing the data in xml accoring to the XSL specifications. I mean who is doing job of formatting or tranforming the data.
how can I make my own Namespace prefix to work?
Like if I want to link a particular Data in the XML to a XSL tranformation with my own predefined tag and make it blinking. so where should I code the blinking functionality?
how to add that in parser so that my XSL output will have Blinking string in its browser window.
Thanks.
------------------
L Goundalkar
lggoundalkar@hotmail.com
Sun Certified Programmer for Java 2 Platform
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic