Welcome to PAKITWORLD!
I hope you will find PAKITWORLD forum useful...



 
HomeCalendarFAQSearchMemberlistUsergroupsLog inRegister
Search
 
 

Display results as :
 
Rechercher Advanced Search
Freelancer.com
Visitors
Live Trafic

Share | 
 

 Spring 2011_CS506_4

View previous topic View next topic Go down 
AuthorMessage
Admin
Admin


Posts : 216
Join date : 2011-06-17
Location : Rawalpindi

PostSubject: Spring 2011_CS506_4   Mon Jun 27, 2011 8:27 pm

Question:
Analyze following code and comment it accordingly showing each code segment impact in the Servlet. After doing so with code write down the purpose of this code in no more than 3-4 sentences. This assignment is based on negative marking if any unnecessary information or too much detail is provided your marks will be deducted.

import java.io.*;
import java.util.*;
import javax.servlet.*;
import javax.servlet.http.*;

public class STimerOut extends HttpServlet {

public void doGet(HttpServletRequest rq, HttpServletResponse rs)
throws ServletException, IOException {
rs.setContentType("text/html");
PrintWriter out = rs.getWriter();
int t = 60;

HttpSession s = rq.getSession();

out.println("");
out.println("");
out.println("");<br /> out.println("Session TimeOut ");<br /> out.println("");
out.println("");


out.println("");
out.println("

");
out.println("Session TimeOut ");
out.println("

");

out.println("gaining the old time out " +
s.getMaxInactiveInterval());

out.println("
");
out.println("
");


s.setMaxInactiveInterval(2*t*t);
out.println("giving new time to get out " +
s.getMaxInactiveInterval());

out.println("");
out.println("");


}
}


Rolling Eyes Rolling Eyes Rolling Eyes
Back to top Go down
View user profile http://pakitworld.board-directory.net
 
Spring 2011_CS506_4
View previous topic View next topic Back to top 
Page 1 of 1
 Similar topics
-
» Tackling Pulai Spring Course
» Park Avenue spring question
» Front spring rates
» KY Horsepower 2011 Spring Shootout (Clay City KY)
» How to get to pulai spring

Permissions in this forum:You cannot reply to topics in this forum
 :: MCS/BCS/MIT/BIT/BSCS :: Assignments-
Jump to: