7.7
Unique Package Names
PACKAGES
create a situation that is difficult or impossible for the user or programmer to
resolve. The class
ClassLoader
 ( 20.14) of the standard Java Virtual Machine
environment can be used to isolate packages with the same name from each other
in those cases where the packages will have constrained interactions, but not in a
way that is transparent to a naive Java program.
You form a unique package name by first having (or belonging to an organiza 
tion that has) an Internet domain name, such as
Sun.COM
. You then reverse this
name, component by component, to obtain, in this example,
COM.Sun
, and use this
as a prefix for your package names, using a convention developed within your
organization to further administer package names.
Such a convention might specify that certain directory name components be
division, department, project, machine, or login names. Some possible examples:
COM.Sun.sunsoft.DOE
COM.Sun.java.jag.scrabble
COM.Apple.quicktime.v2
EDU.cmu.cs.bovik.cheese
GOV.whitehouse.socks.mousefinder
The first component of a unique package name is always written in all uppercase
ASCII letters and should be one of the top level domain names, currently
COM
,
EDU
,
GOV
,
MIL
,
NET
,
ORG
, or one of the English two letter codes identifying coun 
tries as specified in ISO Standard 3166, 1981. For more information, refer to the
documents stored at
ftp://rs.internic.net/rfc
, for example,
rfc920.txt
and
rfc1032.txt
.
The name of a package is not meant to imply anything about where the pack 
age is stored within the Internet; for example, a package named
EDU.cmu.cs.bovik.cheese
 is not necessarily obtainable from Internet address
cmu.EDU
 or from
cs.cmu.EDU
 or from
bovik.cs.cmu.EDU
. The Java convention
for generating unique package names is merely a way to piggyback a package
naming convention on top of an existing, widely known unique name registry
instead of having to create a separate registry for Java package names.
If you need to get a new Internet domain name, you can get an application
form from
ftp://ftp.internic.net
 and submit the complete forms by E mail
to
domreg@internic.net
. To find out what the currently registered domain
names are, you can
telnet
 to
rs.internic.net
 and use the
whois
 facility.
126






footer




 

 

 

 

 Home | About Us | Network | Services | Support | FAQ | Control Panel | Order Online | Sitemap | Contact

java hosting

 

Our partners: PHP: Hypertext Preprocessor Best Web Hosting Java Web Hosting Inexpensive Web Hosting  Jsp Web Hosting

Cheapest Web Hosting Jsp Hosting Cheap Hosting

Visionwebhosting.net Business web hosting division of Web Design Plus. All rights reserved