1. We have moved from vBulletin to XenForo and you are viewing the site in the middle of the move. Though the functional aspect of everything is working fine, we are still working on other changes including the new design on Xenforo.
    Dismiss Notice

Servlet : PrintWriter out = rsp.getWriter(); --what does this do??

Discussion in 'Java' started by sakthi.abdullah, May 8, 2007.

Thread Status:
Not open for further replies.
  1. sakthi.abdullah

    sakthi.abdullah New Member

    Joined:
    Mar 15, 2007
    Messages:
    29
    Likes Received:
    1
    Trophy Points:
    0
    This code is a part of simple HelloWorld Servlet file . Can anyone please explain the highlighted statement ....


    public void doGet(HttpServletRequest req, HttpServletResponse rsp) throws ServletException, IOException {
    rsp.setContentType("text/html");
    PrintWriter out = rsp.getWriter();
    out.println("<html>");


    What does that statement do ??
     
  2. shabbir

    shabbir Administrator Staff Member

    Joined:
    Jul 12, 2004
    Messages:
    15,276
    Likes Received:
    364
    Trophy Points:
    83
    Duplicate of [thread=4225]Servlet : PrintWriter out = rsp.getWriter(); --what does this do??[/thread]. Thread closed.
     
Thread Status:
Not open for further replies.

Share This Page