Link to home
Start Free TrialLog in
Avatar of borg48
borg48

asked on

Java XML Xerces vs Jaxp

I've been looking at both of these and would like to figure out what is the difference.

1.  Ex.  In using DOM are the api calls the same for any of the libraries? Meaning If I was to use Xerces to load an xml document will the code in the jaxp be the same minus the correct libraries to call.
Meaning is the api calls the same in xerces as it is in jaxp?

2. Any opinions on which of the two offers a better performance?  I've played with Xerces 1.x but very little sample or information that its kind of hard.  In Sun's site there are allot of documentation on Jaxp.  And I read that the xerces 2.x is going to be different so does that create a new learning curve again.

Thanks
Avatar of ozymandias
ozymandias
Flag of United Kingdom of Great Britain and Northern Ireland image

Avatar of borg48
borg48

ASKER

So is crimson a more up to date level library then xerces 1.0?

It seems to use the jaxp api in crimson so why not use jaxp? Any differences?

Are the api calls in jaxp the same for crimson since they both use the same dom, sax, etc level?  Meaning to open a dom document is it the same in jaxp as it is in crimson?

Thanks
borg48,

As far as I know JAXP isn't a parser implementation. It's a set of APIs that abstract the use of XML parsers, so that you can switch parsers without changing application code (like JMS does for messaging). Apache Crimson is _one_ particular _implementation_ of an XML parser that you get with the JAXP distribution, but it's not part of the API per se.

Other XML parsers that can be "plugged into" the JAXP APIs are Apache Xerces (1/2), Sun Project X, IBM XML4J, etc.

Regards,
WMB
Avatar of borg48

ASKER

Hi wbradney
  Excuse my ignorance in this but i'm just trying to clear up my understanding.  
So are  you saying that I can download the JAXP jar file and the xerces 2 jar file and program to the jaxp api.  Which in turn will use the xerces 2 api to do the actual parsing?
Is this a standard method of doing?

Does jaxp also use the xalan xslt for transformation?

Thanks for any input.
ASKER CERTIFIED SOLUTION
Avatar of Wayne Bradney
Wayne Bradney
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial