You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
49 lines
1.4 KiB
49 lines
1.4 KiB
package kr.co.kihyun.beans.user; |
|
|
|
import java.io.PrintWriter; |
|
import java.sql.SQLException; |
|
import java.util.logging.Level; |
|
import java.util.logging.Logger; |
|
|
|
import javax.servlet.annotation.WebServlet; |
|
import javax.servlet.http.HttpServlet; |
|
import javax.servlet.http.HttpServletRequest; |
|
import javax.servlet.http.HttpServletResponse; |
|
import kr.co.kihyun.lang.MString; |
|
|
|
import kr.co.kihyun.beans.user.MultiCheck; |
|
|
|
@WebServlet("/servlet/kr.co.kihyun.beans.user.HttpMultiCheckCount") |
|
public class HttpMultiCheckCount extends HttpServlet |
|
{ |
|
@Override |
|
public void doGet(HttpServletRequest req, HttpServletResponse res) { |
|
doPost(req,res); |
|
return; |
|
} |
|
|
|
|
|
@Override |
|
public void doPost(HttpServletRequest req, HttpServletResponse res) { |
|
String sUserId = MString.checkNull(req.getParameter("userId")); |
|
int iCount = -1; |
|
|
|
try { |
|
MultiCheck mc = new MultiCheck(); |
|
|
|
mc.IdCheck(sUserId); |
|
iCount = mc.getCount(); |
|
|
|
res.setContentType("text/html;charset=UTF-8"); |
|
PrintWriter out = res.getWriter(); |
|
out.println(Integer.toString(iCount)); |
|
|
|
} catch (SQLException ex) { |
|
java.util.logging.Logger.getLogger(HttpApproveSet.class.getName()).log(Level.SEVERE, null, ex); |
|
} catch (Exception ex) { |
|
Logger.getLogger(HttpMultiCheckCount.class.getName()).log(Level.SEVERE, null, ex); |
|
} finally { |
|
|
|
} |
|
} |
|
}
|
|
|