Home  >  Article  >  Java  >  What is a servlet file?

What is a servlet file?

little bottle
little bottleOriginal
2019-05-13 16:13:295688browse

Servlet (Server Applet) is the abbreviation of Java Servlet. It is called a small service program or service connector. It is a server-side program written in Java. It has the characteristics of being independent of platform and protocol. Its main function is to browse and generate interactively. data to generate dynamic web content.

What is a servlet file?

Servlet is a class. The servlet file is a java class file.

Initially there was no jsp, only servlet, which means that the initial development process was .java->.class. Later, because writing html code in servlet was too cumbersome, the jsp type was added. The main functions of servlets in JavaWeb are to carry network connections and business logic processing, such as conversion of some encoding formats, login interception, etc.

In the narrow sense, Servlet refers to an interface implemented by the Java language. In the broad sense, Servlet refers to any class that implements this Servlet interface. Generally, people understand Servlet as the latter. Servlets run in Java-enabled application servers. In principle, Servlets can respond to any type of request, but in most cases Servlets are only used to extend Web servers based on the HTTP protocol.

The above is the detailed content of What is a servlet file?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn