Package Naming Best Practices  
Author Message
Brad BARCLAY





PostPosted: 2003-6-26 13:55:00 Top

java-programmer, Package Naming Best Practices Steven Garcia wrote:

> Is this inadvisable? On one hand it provides clarity for the classes
> in a package, on the other hand that clarity might confuse those who
> are really familiar with the Java API.

As it doesn't follow the package naming specification, I'd say you need
to modify your approch somewhat.

As you don't own the rights to the Java API (or the Java name), it
might be better to instead use the following, which would comply with
the spec:

net.domainname.mp.lang
net.domainname.mp.text
net.domainname.mp.util
net.domainname.mp.io
...etc.

That's my advice -- you're welcome to use it or ignore it as it suits
you :).

HTH!

Brad BARCLAY

--
=-=-=-=-=-=-=-=-=
From the OS/2 WARP v4.5 Desktop of Brad BARCLAY.
The jSyncManager Project: http://www.jsyncmanager.org


 
blunck





PostPosted: 2003-7-4 11:49:00 Top

java-programmer >> Package Naming Best Practices Hi Brad-

I'd prefix your distro with com.mp instead of just mp.java.lang. Even
then, I wouldn't reuse the java.* packages - it'd confuse me.


-c


email***@***.com (Steven Garcia) wrote in message news:<email***@***.com>...
> I am designing a set of utility classes that extend the core Java API.
> For instance I'm creating additional implementations of Collection /
> Maps, more classes that act on text, I/O classes, even some for
> Strings.
>
> I thought about lumping these into packages for my application under
> the same namespace the would for the core Java API, but under our
> application's root name. So instead of
>
> java.lang
> java.text
> java.util
> java.io
> ...
>
> it would be
>
> mp.java.lang
> mp.java.text
> mp.java.util
> mp.java.io
>
> Is this inadvisable? On one hand it provides clarity for the classes
> in a package, on the other hand that clarity might confuse those who
> are really familiar with the Java API.