标签:io java sp on bs res as 简单 class
package xby;
import java.io.*;
import javax.servlet.*;
public class firstservlet extends GenericServlet{
public void service(ServletRequest req,ServletResponse res)throws ServletException, java.io.IOException
{
OutputStream out= res.getOutputStream();
out.write("Hello Servlet".getBytes());
}
}
set classpath=%classpath%;C:\apache-tomcat-7.0.55\lib
javac -d . firstservlet.java
标签:io java sp on bs res as 简单 class
原文地址:http://www.cnblogs.com/boyangx/p/4013381.html