Servlets API, Packages are used in Java in order to prevent naming conflicts, to avoid naming clashes, to control access, to make seeking/finding and use of classes, interfaces , lists. A Package can be characterized as a gathering of related sorts (classes, interfaces, identifications and comments ) giving access security and name space administration. Following are the packages of Servlet API. While developing an application developer need to import this packages otherwise errors occur automatically and asks to import.
javax.servlet.*
javax.servlet.http.*
javax.servlet.*package contains a number of classes and interfaces that define the agreement between the servlet class and the run-time environment provided an instance of the servlet class by a conforming servlet container.
javax.servlet.http.* package contains a number of classes and interfaces that define the agreement between the servlet class under HTTP protocol and the run-time environment provide an instance of the servlet class by conforming servlet container.
Click Here To Know More About Interfaces
Conceptual
Figure
Following is the figure which describes the packages of javax.servlet .