What are the usages of package in java? , JAVA Programming

It helps to resolve naming conflicts when different packages have classes with the same names. This also helps you prepare files within your project. As define: java.io package do something related to input output and java.net package do something to do with network and so on. If we toward to put all .java files into a single package, as the project gets larger, then it would become a nightmare to manage all your files. You may create a package as follows with package keyword, which is the first keyword in any Java program followed by import statements. The java.lang package is imported implicitly by default when a java program created and all the other packages must be explicitly imported when a java program created.

 

package com.xyz.client ;

import java.io.File;

import java.net.URL;

 

Posted Date: 7/25/2012 12:25:39 AM | Location : United States







Related Discussions:- What are the usages of package in java? , Assignment Help, Ask Question on What are the usages of package in java? , Get Answer, Expert's Help, What are the usages of package in java? Discussions

Write discussion on What are the usages of package in java?
Your posts are moderated
Related Questions
What does it mean that a method or class is abstract? An abstract class cannot be instantiated. Abstract methods may only be included in abstract classes. However, an abstract

RMI parameters : Primitive types are given by value. 2. References to remote objects are given as remote references that allow the client process to call methods on the rem

Project Description: We need to develop software that has a database of players with the ability to delete and add players at will, once captured there can be a draw to set them

iiiiii

The typical use of the roster class is to display a tree view of groups and entries along with the current presence value of each entry. As an example, see the image showing a Rost

Explain what is Naming Applets in java applets? You can give an applet a name by using the NAME attribute of the APPLET element. This allows communication between different app

Texas Hold'em Poker Java Game Source Code Project Description: I am seeking Java source code for a Texas Hold'em Poker game. The game could have client and server side mod

What do you mean about networking support in Java ?

How is method overriding different from method overloading? Overriding involves the creation of two or more concepts with the same name and same signature in different classes