Questions Related to technology

Multiple choice technology web technology
  1. <jsp:declareBean id = "harry" class = "EmployeeBean" scope = "request" />

  2. <jsp:createBean id = "harry" class = "EmployeeBean" />

  3. <jsp:useBean id = "harry" class = "EmployeeBean" scope = "request" />

  4. <jsp:useBean id = "harry" class = "EmployeeBean" />

Reveal answer Fill a bubble to check yourself
C Correct answer
Multiple choice technology web technology
  1. <taglib> <uri>http://www.javabeat.net/studyKit&lt;/uri> <location>/studyKit.tld</location> </taglib>

  2. <taglib> <uri>http://www.javabeat.net/studyKit&lt;uri> <location>/studyKit.tld</location> </taglib>

  3. <taglib> <taglib-uri>http://www.javabeat.net/studyKit&lt;/taglib-uri> <taglib-location>/studyKit.tld</taglib-location> </taglib>

  4. <taglib> <uri>http://www.javabeat.net/studyKit&lt;/uri> <path>/studyKit.tld</path> </taglib>

Reveal answer Fill a bubble to check yourself
C Correct answer
Multiple choice technology web technology
  1. Define a listener class implementing HttpSessionListener and whenever an object is added to Http Session object, keep track of the number of instances.

  2. Define a listener class implementing HttpSessionBindingListener and in the valueBound() method, keep track of the number of instances being added in a static variable.

  3. It is highly impossible to keep track the number of objects being added to a Http Session in a Web Application.

  4. The Servlet API provides direct support for keeping track the object instances.

Reveal answer Fill a bubble to check yourself
B Correct answer
Multiple choice technology web technology
  1. Use the method 'HttpServletRequest.getParameterNames()' which will return an enumeration of parameter names.

  2. Use the method 'HttpServletResponse.getParameterNames()' which will return an enumeration of parameter names.

  3. Use the method 'HttpServletRequest.getAllParameters()' which will return an enumeration of parameter names.

  4. There is no direct support in the Servlet API to retrieve the name of all the parameters sent by the client.

Reveal answer Fill a bubble to check yourself
A Correct answer
Multiple choice technology web technology
  1. The value of the 'test' variable will be 2.

  2. The value of the 'test' variable will be 0.

  3. The value of the 'test' variable will be 1.

  4. The variable 'test' must be declared at global scope, else a run-time error will occur

Reveal answer Fill a bubble to check yourself
C Correct answer