aspose file tools*
The moose likes XML and Related Technologies and the fly likes SAX start element why uri is empty Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "SAX start element why uri is empty" Watch "SAX start element why uri is empty" New topic
Author

SAX start element why uri is empty

Sergio Gazzini
Greenhorn

Joined: May 29, 2011
Posts: 12
I try understand SAX but cannot understand
this example:


Why on the start of element uri is empty? URI = unique resource indentifier IMHO.
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18662
    
    8

That would be because the element in question doesn't have a namespace, and so there's no namespace URI.

Of course I have to say that without being able to see the XML in question, so I can't tell why you think it's wrong. Perhaps you could explain what you think you should see there?

And the documentation of that method also says this:

Any or all of these may be provided, depending on the values of the http://xml.org/sax/features/namespaces and the http://xml.org/sax/features/namespace-prefixes properties


You didn't mention what the values of those properties were, either.
Sergio Gazzini
Greenhorn

Joined: May 29, 2011
Posts: 12
Paul Clapham wrote:That would be because the element in question doesn't have a namespace, and so there's no namespace URI.

Of course I have to say that without being able to see the XML in question, so I can't tell why you think it's wrong. Perhaps you could explain what you think you should see there?

And the documentation of that method also says this:

Any or all of these may be provided, depending on the values of the http://xml.org/sax/features/namespaces and the http://xml.org/sax/features/namespace-prefixes properties


You didn't mention what the values of those properties were, either.


Understand, sorry for my error URI - unified...

Thanks.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: SAX start element why uri is empty