You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by Kevin Kress <Ke...@oracle.com> on 2000/09/07 02:30:52 UTC
JDOM and javax.* classes
hello all,
I have 2 questions about xerces and non-W3 standards.
1) I have been poking around the CVS tree and saw the javax.xml.parsers
package I assume this is to mimic the sun java standard jaxp
interfaces. I had asked about a bug I found in there earlier, is this
something that is actually supported by xerces or is this something that
just works now (as of 1.1.3) and may not be there later?
2) I was looking at the list of reqs. for Xerces 2 and saw that the
requirement (#31) for JDOM support is soft (and unevaluated). What are
the plans for JDOM support in xerces? I would think that this should be
a hard requirement. Agreed it is not a W3 standard, but it seems to be
a standard none the less and IMHO xerces should support it.
Thanks
Kevin Kress
Re: JDOM and javax.* classes
Posted by Arnaud Le Hors <le...@us.ibm.com>.
Kevin Kress wrote:
>
> hello all,
>
> I have 2 questions about xerces and non-W3 standards.
>
> 1) I have been poking around the CVS tree and saw the javax.xml.parsers
> package I assume this is to mimic the sun java standard jaxp
> interfaces. I had asked about a bug I found in there earlier, is this
> something that is actually supported by xerces or is this something that
> just works now (as of 1.1.3) and may not be there later?
As far as I understand this is a supported feature. The only problem is
probably that Pier, who contributed the code in the first place, doesn't
seem to have time to dedicate to this project anymore and he hasn't
picked up your bug report. I'd expect Sun would care to maintain this
bit though. And I would think that the fact that Pier now works for Sun
should only make this easier. But I'm speculating entirely here, I'll
leave to the Sun people to tell us more.
> 2) I was looking at the list of reqs. for Xerces 2 and saw that the
> requirement (#31) for JDOM support is soft (and unevaluated). What are
> the plans for JDOM support in xerces? I would think that this should be
> a hard requirement. Agreed it is not a W3 standard, but it seems to be
> a standard none the less and IMHO xerces should support it.
I wonder on what basis you think it's a standard but, anyway, we've
already said that we want Xerces 2 to be more modular and to provide an
API that would allow several APIs to sit on top. It's up to people like
you, who care about JDOM, to make sure it works for JDOM as well.
--
Arnaud Le Hors - IBM Cupertino, XML Technology Group
Re: JDOM and javax.* classes
Posted by James Duncan Davidson <du...@x180.com>.
on 9/7/00 1:22 PM, Andy Clark at andyc@apache.org wrote:
> Kevin Kress wrote:
>> Then why not just split the current jar file in two?
>
> Just splitting the jar file into two doesn't address the real
> question which is: [Q] Should Xerces ship the extensions or
> should they be downloaded by users as needed?
See other "would you like fries with that" post for my opinion.
> I would rather see a "conrib" zone of the site and that the
> contributors are always the ones responsible to keep their
> extensions working and support them. I don't like pushing
> extensions into the Xerces release. I want them separate.
On the contrary side, some extensions *should* be part of the core (at least
the core release with fries) release as if you always marginalize them, then
people don't see them as first class.
.duncan
Re: JDOM and javax.* classes
Posted by Andy Clark <an...@apache.org>.
Kevin Kress wrote:
> Then why not just split the current jar file in two?
Just splitting the jar file into two doesn't address the real
question which is: [Q] Should Xerces ship the extensions or
should they be downloaded by users as needed?
By shipping all of the extensions, you have a number of issues:
you have to make sure that all the extensions continue to work
(which can be troublesome as the number of extensions increase);
the size of the jar increases over time; and you have the
feeling of "endorsement" of extensions.
I would rather see a "conrib" zone of the site and that the
contributors are always the ones responsible to keep their
extensions working and support them. I don't like pushing
extensions into the Xerces release. I want them separate.
--
Andy Clark * IBM, JTC - Silicon Valley * andyc@apache.org
Re: JDOM and javax.* classes
Posted by Kevin Kress <Ke...@oracle.com>.
> I still think we need to come up with a system for making and
> distributing contributed packages such as JDOM that are built
> on top of the parser internals. We both agree that supporting
> JDOM (or anything else) should not directly impact the size
> of the parser jar file because it's *supplemental*, not core.
>
> Which leads me to my standard rant that we have too much
> stuff in the parser jar file. I think only core functionality
> should be in the jar file and that all supplemental code
> would have its own packaging. For example: serializers, HTML,
> WML, and perhaps even DOM. I see SAX as core functionality.
Then why not just split the current jar file in two?
For what I have gathered from browsing the CVS tree (mind you this may
be completely off base since I don't know all the package dependencies)
packaging the entire org.xml.w3c.dom, org.xml.sax and most of
org.apache.xerces into 1 core jar would make a minimalist distribution.
The rest could be packaged separately as add-on's. What we should
probably consider is branching the current org.apache.xerces package and
org.apache.xml into "core" and "extension".
Core would contain the Impl's for SAX 1/2 and DOM 1(/2?/3?) and nothing
else (unless I am missing something). Then things like the current
org.apache.xerces.jaxp packages could be moved into the "extension"
package, where things like JDOM, WML, HTML, (the serializer?) could
live. This gives a clear break between core and exts.
Again I don't know how much cross dependencies there are now, but that
seems like the logical solution.
just my 2 cents
--Kevin
Re: JDOM and javax.* classes
Posted by James Duncan Davidson <du...@x180.com>.
on 9/7/00 10:40 AM, Andy Clark at andyc@apache.org wrote:
> Which leads me to my standard rant that we have too much
> stuff in the parser jar file. I think only core functionality
> should be in the jar file and that all supplemental code
> would have its own packaging. For example: serializers, HTML,
> WML, and perhaps even DOM. I see SAX as core functionality.
Yep.. Seperate .jar files packaged up a couple of ways on the download page:
"Welcome to dist.xml.apache.org, my I take your order please?
Do you want core core smallest possible parser distro (SAX)?
Would you like DOM with that?
Would you like JDOM with that?
Here's your link.. Have fun...."
.duncan
Re: JDOM and javax.* classes
Posted by Andy Clark <an...@apache.org>.
Brett McLaughlin wrote:
> JDOM is not directly support by Xerces now, it is indirectly
> supported. I wrote a fancy SAXBuilder to build a JDOM Document,
> so it is supported indirectly.
This is a choice that you made as a JDOM developer. There's
nothing preventing you from writing a class that extends the
base XMLParser to build and return a JDOM document. I *do*
understand, however, that this has its own perils seeing as
how those interfaces have changed to support Schema features.
But the idea with Xerces 2 is that we know enough about the
information that we need to get out of the parser in order
to be better at settling on a standard set of internal
interfaces. And in this case you'd do the same thing -- just
implement a JDOMParser that would build a JDOM tree from the
internal callbacks.
I still think we need to come up with a system for making and
distributing contributed packages such as JDOM that are built
on top of the parser internals. We both agree that supporting
JDOM (or anything else) should not directly impact the size
of the parser jar file because it's *supplemental*, not core.
Which leads me to my standard rant that we have too much
stuff in the parser jar file. I think only core functionality
should be in the jar file and that all supplemental code
would have its own packaging. For example: serializers, HTML,
WML, and perhaps even DOM. I see SAX as core functionality.
--
Andy Clark * IBM, JTC - Silicon Valley * andyc@apache.org
Re: JDOM and javax.* classes
Posted by Brett McLaughlin <br...@lutris.com>.
Andy Clark wrote:
>
> Kevin Kress wrote:
> > 2) I was looking at the list of reqs. for Xerces 2 and saw that the
> > requirement (#31) for JDOM support is soft (and unevaluated). What
> > are the plans for JDOM support in xerces? I would think that this
> > should be a hard requirement. Agreed it is not a W3 standard, but
> > it seems to be a standard none the less and IMHO xerces should
> > support it.
>
> JDOM can be implemented on the current parser (and is). So I
> don't see why it needs to be a "hard" requirement to support
> any implementation of an API -- it will be able to support
> *all* APIs.
Just for clarification-
JDOM is not directly support by Xerces now, it is indirectly supported.
I wrote a fancy SAXBuilder to build a JDOM Document, so it is supported
indirectly. Additionally, you can't use Xerces to get a JDOM Document,
you have to use JDOM wrapping Xerces. What I am going to make sure
happens in Xerces 2 is that it is directly supported. So you can get a
JDOM Document straight from Xerces 2, and preferably have it built from
the internals, not second-hand. And if it's not a hard requirement to
support JDOM, or any APIs, then it's not a hard requirement to support
SAX and DOM; of course that's silly, as of course it /must/ support DOM
and SAX. But it's always been implied that JDOM support will be there,
as long as I do the work, with others' help. So that's the whole story
;-)
-Brett
>
> --
> Andy Clark * IBM, JTC - Silicon Valley * andyc@apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-j-dev-help@xml.apache.org
--
Brett McLaughlin, Enhydra Strategist
Lutris Technologies, Inc.
1200 Pacific Avenue, Suite 300
Santa Cruz, CA 95060 USA
http://www.lutris.com
http://www.enhydra.org
Re: JDOM and javax.* classes
Posted by Andy Clark <an...@apache.org>.
Kevin Kress wrote:
> 2) I was looking at the list of reqs. for Xerces 2 and saw that the
> requirement (#31) for JDOM support is soft (and unevaluated). What
> are the plans for JDOM support in xerces? I would think that this
> should be a hard requirement. Agreed it is not a W3 standard, but
> it seems to be a standard none the less and IMHO xerces should
> support it.
JDOM can be implemented on the current parser (and is). So I
don't see why it needs to be a "hard" requirement to support
any implementation of an API -- it will be able to support
*all* APIs.
--
Andy Clark * IBM, JTC - Silicon Valley * andyc@apache.org
Re: JDOM and javax.* classes
Posted by James Duncan Davidson <du...@x180.com>.
on 9/8/00 11:28 AM, Andy Clark at andyc@apache.org wrote:
> I think this discussion has gotten out of control and we're
> all guilty (myself included ;). The question for me is not
> really JDOM but how we handle *all* contributions.
If people are willing to work on it, then the door should be open. If people
aren't willing, then the door should be closed.
> Throwing every contribution into the Xerces distribution
> causes problems. Would people generally agree with this?
Throwing every contribution that didn't come with a maintainer, yes. But I
think that there are plenty of people here that will take care of the JDOM
part.
.duncan
Re: JDOM and javax.* classes
Posted by Andy Clark <an...@apache.org>.
I think this discussion has gotten out of control and we're
all guilty (myself included ;). The question for me is not
really JDOM but how we handle *all* contributions.
Throwing every contribution into the Xerces distribution
causes problems. Would people generally agree with this?
--
Andy Clark * IBM, JTC - Silicon Valley * andyc@apache.org
Re: JDOM and javax.* classes
Posted by Andy Clark <an...@apache.org>.
Brett McLaughlin wrote:
> Because it is _slower_ to use SAX to build a JDOM tree than to
> build it directly. Easy question to answer. Why should I be
> penalized when it costs you absolutely nothing to support this
> increase in performance for an emerging standard.
I'll say it again: there's absolutely nothing preventing you
from building it directly from the parser internal callbacks.
But I don't think that requiring Xerces to provide this class
is needed. The JDOM community can provide that class.
Please stop calling your own invention an "emerging standard".
The industry will decide that.
--
Andy Clark * IBM, JTC - Silicon Valley * andyc@apache.org
Re: JDOM and javax.* classes
Posted by Brett McLaughlin <br...@lutris.com>.
Arnaud Le Hors wrote:
>
> Whether I like JDOM or not has nothing to do with it. It's in our
> mission statement to be based on standards. See
> http://xml.apache.org/mission. I don't think your argument that SAX is
> no more a standard than JDOM holds at all. SAX clearly is a de facto
> standard, I don't think you can find anybody to disagree with that. This
> is clearly not true for JDOM. At least not yet.
> In addition, the fact that SAX and DOM are interfaces, as opposed to
> JDOM which is made of classes, makes a big difference. If we don't
> implement SAX and DOM interfaces, we simply don't support them at all.
> The same is not true for JDOM. Again, there is no TECHNICAL reason to
> have a JDOM builder in Xerces. If Xerces provides a powerful API that
> delivers all the information you need, what is it that you could do as
> part of Xerces that you couldn't simply do in JDOM???
Because it is _slower_ to use SAX to build a JDOM tree than to build it
directly. Easy question to answer. Why should I be penalized when it
costs you absolutely nothing to support this increase in performance for
an emerging standard.
-Brett
> --
> Arnaud Le Hors - IBM Cupertino, XML Technology Group
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-j-dev-help@xml.apache.org
--
Brett McLaughlin, Enhydra Strategist
Lutris Technologies, Inc.
1200 Pacific Avenue, Suite 300
Santa Cruz, CA 95060 USA
http://www.lutris.com
http://www.enhydra.org
Re: JDOM and javax.* classes
Posted by Arnaud Le Hors <le...@us.ibm.com>.
Whether I like JDOM or not has nothing to do with it. It's in our
mission statement to be based on standards. See
http://xml.apache.org/mission. I don't think your argument that SAX is
no more a standard than JDOM holds at all. SAX clearly is a de facto
standard, I don't think you can find anybody to disagree with that. This
is clearly not true for JDOM. At least not yet.
In addition, the fact that SAX and DOM are interfaces, as opposed to
JDOM which is made of classes, makes a big difference. If we don't
implement SAX and DOM interfaces, we simply don't support them at all.
The same is not true for JDOM. Again, there is no TECHNICAL reason to
have a JDOM builder in Xerces. If Xerces provides a powerful API that
delivers all the information you need, what is it that you could do as
part of Xerces that you couldn't simply do in JDOM???
--
Arnaud Le Hors - IBM Cupertino, XML Technology Group
Re: JDOM and javax.* classes
Posted by Brett McLaughlin <br...@lutris.com>.
Arnaud Le Hors wrote:
>
> Brett McLaughlin wrote:
> >
> > JDOM is not directly support by Xerces now, it is indirectly supported.
> > I wrote a fancy SAXBuilder to build a JDOM Document, so it is supported
> > indirectly. Additionally, you can't use Xerces to get a JDOM Document,
> > you have to use JDOM wrapping Xerces. What I am going to make sure
> > happens in Xerces 2 is that it is directly supported. So you can get a
> > JDOM Document straight from Xerces 2, and preferably have it built from
> > the internals, not second-hand. And if it's not a hard requirement to
> > support JDOM, or any APIs, then it's not a hard requirement to support
> > SAX and DOM; of course that's silly, as of course it /must/ support DOM
> > and SAX. But it's always been implied that JDOM support will be there,
> > as long as I do the work, with others' help. So that's the whole story
> > ;-)
>
> I guess we're going to disagree here (which won't be so much of a
> surprise I guess). I don't see Xerces depending on anything from JDOM,
> so I don't see how it could "directly" support JDOM. And I really don't
> see any technical reason to do that. Again, I agree Xerces should
> provide an API powerful enough for you to get all the information you
> need for JDOM, but that's all. The JDOM builder should stay in JDOM.
Why? You don't require SAX to be self-contained - you can get a SAX
parser directly from Xerces. Why can't I get a JDOM parser, or a JDOM
document? SAX is no more standard in the formal sense than JDOM... If we
had JDOM as interfaces, I suppose you would vote against Xerces having
an implementation of JDOM as well, which is also something I son't
understand. As long as Xerces is modular, and you don't have to get this
when you get the core Xerces, I really don't see how you can make an
argument.
1) It won't affect your jar size
2) It won't affect your memory footprint
3) It won't affect your efforts
The only reason left is that you don't like JDOM, which has no place on
a public project like this; I think DOM is close to worthless is many,
many situations in Java, but you don't see me arguing against using it!
Because in Xerces 2
1) It won't affect my jar size
2) It won't affect my memory footprint
3) It won't affect my efforts
Seems QED to me.
-Brett
> --
> Arnaud Le Hors - IBM Cupertino, XML Technology Group
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-j-dev-help@xml.apache.org
--
Brett McLaughlin, Enhydra Strategist
Lutris Technologies, Inc.
1200 Pacific Avenue, Suite 300
Santa Cruz, CA 95060 USA
http://www.lutris.com
http://www.enhydra.org
Re: JDOM and javax.* classes
Posted by James Duncan Davidson <du...@x180.com>.
on 9/7/00 9:11 AM, Arnaud Le Hors at lehors@us.ibm.com wrote:
> I guess we're going to disagree here (which won't be so much of a
> surprise I guess). I don't see Xerces depending on anything from JDOM,
> so I don't see how it could "directly" support JDOM. And I really don't
> see any technical reason to do that. Again, I agree Xerces should
> provide an API powerful enough for you to get all the information you
> need for JDOM, but that's all. The JDOM builder should stay in JDOM.
Of course there shouldn't be any dependancies inside of the core Xerces on
JDOM, that's the wrong direction for dependancies to go.. :)
We should have JDOM layer ontop of Xerces (through one if its adapters maybe
and sitting on the API layer that the SAX and DOM chunks sit on) and it
should be part of our distribution package.. You get Xerces2, you can use
JDOM right off the bat. The codebase for JDOM (except for the builder) need
not be over here, just a jdom.jar checked in and synched.
.duncan
Re: JDOM and javax.* classes
Posted by Arnaud Le Hors <le...@us.ibm.com>.
Brett McLaughlin wrote:
>
> JDOM is not directly support by Xerces now, it is indirectly supported.
> I wrote a fancy SAXBuilder to build a JDOM Document, so it is supported
> indirectly. Additionally, you can't use Xerces to get a JDOM Document,
> you have to use JDOM wrapping Xerces. What I am going to make sure
> happens in Xerces 2 is that it is directly supported. So you can get a
> JDOM Document straight from Xerces 2, and preferably have it built from
> the internals, not second-hand. And if it's not a hard requirement to
> support JDOM, or any APIs, then it's not a hard requirement to support
> SAX and DOM; of course that's silly, as of course it /must/ support DOM
> and SAX. But it's always been implied that JDOM support will be there,
> as long as I do the work, with others' help. So that's the whole story
> ;-)
I guess we're going to disagree here (which won't be so much of a
surprise I guess). I don't see Xerces depending on anything from JDOM,
so I don't see how it could "directly" support JDOM. And I really don't
see any technical reason to do that. Again, I agree Xerces should
provide an API powerful enough for you to get all the information you
need for JDOM, but that's all. The JDOM builder should stay in JDOM.
--
Arnaud Le Hors - IBM Cupertino, XML Technology Group
Re: JDOM and javax.* classes
Posted by James Duncan Davidson <du...@x180.com>.
on 9/6/00 5:30 PM, Kevin Kress at Kevin.Kress@oracle.com wrote:
> 1) I have been poking around the CVS tree and saw the javax.xml.parsers
> package I assume this is to mimic the sun java standard jaxp
> interfaces.
Implement the interfaces, not mimic. :)
> I had asked about a bug I found in there earlier, is this
> something that is actually supported by xerces or is this something that
> just works now (as of 1.1.3) and may not be there later?
Should be supported. I'll ask one of the guys at Sun to take a look at it.
> 2) I was looking at the list of reqs. for Xerces 2 and saw that the
> requirement (#31) for JDOM support is soft (and unevaluated). What are
> the plans for JDOM support in xerces? I would think that this should be
> a hard requirement. Agreed it is not a W3 standard, but it seems to be
> a standard none the less and IMHO xerces should support it.
Xerces should... Hopefully we'll see it. :)
.duncan