本文介绍了out.println说出来无法解决的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
当我写 out.println()
时,eclipse会抱怨无法解决。
When I write out.println()
, eclipse complains that out cannot be resolved.
我有导入 java.io。*
和其他servlet包。
I have imported java.io.*
and other servlet packages.
推荐答案
在黑暗中拍摄,我认为这是你要找的 out
:
Just a shot in the dark, I think this is the out
you are looking for:
public class OutServlet extends HttpServlet {
public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
PrintWriter out = response.getWriter();
out.println("foo");
}
}
这篇关于out.println说出来无法解决的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!