![]() |
![]() |
Java Packages | |
Java Built in packages | |
Java Package Access Specifiers |
Introduction of Errors | |
Java Exceptions | |
Java Try Block | |
Java Catch Block | |
Java Finally Block | |
Java Throw Keyword | |
Java Throws Keyword | |
Java Builtin Exceptions | |
User Defined Exceptions |
Java Multithreading | |
Creating a Thread | |
Thread Life Cycle | |
Thread Exceptions | |
Thread Synchronization |
Java Programs | |
Java Keywords Dictionary | |
Java Interview Questions |
Java API provides a number of classes grouped into different packages according to their functionality.
These packages consist of a large number of classes which are a part of java API.
Following are some mostly used java packages which are located in java
Package Name | Description / USE |
---|---|
java.lang |
This package contains language support classes. This package is automatically imported by java compiler for itself use. Classes : Integer,String,Math,Exception etc Interfaces : Runnable,Comparable,Readable etc |
java.util | These are the language utility classes. Classes : Scanner,Vector,Array,Date,Random,Timer,LinkedList etc Interfaces : Collection, Deque, Iterator, Set etc |
java.io | These are the input/output support classes. They provides many facilities for I/O Operations Classes : BufferedReader,InputStreamReader,Console,File,FileReader,FileWritter etc Interfaces : DataOutput,DataInput,Flushable,Serializable etc |
java.awt | It contains the set of classes for implementing graphical user interface (GUI) such as button,window,menus etc. Classes : Color,Button,TextField,Window,Graphics2D etc Interfaces : LayoutManager,ActiveEvent,Shape,Stroke etc |
java.net | It contains the classes for networking for communication with two local computers also with servers. Classes : DatagramSocket,HttpURLConnection,InetAddress,Proxy,Socket,URL etc Interfaces : CookiePolicy,SocketOptions etc |
java.applet | It contains the class for creating and implenting applets. Applets are running programs on internet Classes : Applet Interfaces : AppletContext,AudioClip etc |
Naming conventions allows us to differentiate between classes and other packages. So that we can easily identify which one is class and which is one is the package.