"Aaron M. Renn" wrote:
>
> I'm opposed to org.gnu for the same reason that I hate email addresses
> of the form [EMAIL PROTECTED] It purports to be some type of
> globally unique identifier when in fact it is not. In the meantime,
> it requires names that are extremely verbose. At my last company
> we had two Gregory R. Barrett's. One of them ended up a gregory.r.barrett
> and the other at greg.r.barrett. It's like making your hash table
> really, really big in the hopes you won't have a collision.
I'm not quite sure that follows... so long as each package has a
defined owner who controls what goes in it, there should never be a
namespace collision using the standard Java system. Okay, code-forks
spoil this a little bit, but I think the principle still holds.
Actually, I'd go so far as to say that one of the really cool things
about Java is that it DOES encourage people to give every class a
globally unique identifier, and this is a Good Thing for efficient code
reuse.
It's an unfortunate fact that it's hard to have useful unique
identifiers without using some form of central registry. One option
would have been for Sun to run such a registry themselves, but I'm sure
that would have led to all manner of cries of foul play (and they might
well have charged for registrations, which I dare say would have led to
even more complains). Using the DNS as the registry for Java package
names seems a very neat way out of the problem, and while I accept that
the names aren't especially pretty, I don't think they cause any real
problems -- and normally they only affect the package and import
statements at the top of the source files, anyway.
It's kind-of a pity that there are sun.* packages, but to be fair, some
of these must have existed before the current naming scheme was
developed. And Sun do sometimes set a good example: before Swing moved
to its new home in javax, it was always com.sun.swing, and all the Jini
stuff lives in net.jini.
In reality, having things in gnu.* isn't actually doing anybody any
harm, but I'm not sure it's something that anyone can get moralistic
about, given that Sun are pretty clear as to how things are supposed to
work, and you can't really argue that it's not fair. Of course, if
people asked Sun nicely, they might even approve gnu as an `official'
top level package -- but think carefully before trying that one, it
might just be opening pandora's box.
Thomas.