您确定确实覆盖了doPost方法吗?
签名如下所示:
protected void doPost(HttpServletRequest req, HttpServletResponse resp)throws ServletException, java.io.IOException
但您可以这样指定:
public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException, IllegalStateException
请尝试以下步骤:
- 添加@Override注释
- 删除抛出的IllegalStateException(这不是问题,因为它是运行时异常)
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)