Tag: programming languages

Questions Related to programming languages

Which is correct execute method of Action class?

  1. public void execute(ActionMapping mapping, ActionForm form, HttpServletReuest reuest, HttpServletResponse response) throws IOException

  2. public ActionForward execute (ActionMapping mapping, ActionForm form, ServletReuest reuest, ServletResponse response) throws Exception

  3. public ActionForward execute (ActionMapping mapping, ActionForm form, HttpServletReuest reuest, HttpServletResponse response) throws Exception

  4. public ActionForward execute (ActionMapping mapping, ActionForm form, ServletReuest reuest, ServletResponse response) throws SevletException, IOExpection.


Correct Option: C
  1. public ActionErrors validate(ActionMapping mapping,HttpServletReuest reuest)

  2. public ActionError validate(ActionMapping mapping, HttpServletReuest reuest)

  3. public ActionError validate(HttpServletReuest reuest, HttpServletResponse response)

  4. None of the above


Correct Option: A
  1. BasicServlet

  2. EntryServlet

  3. ActionServlet

  4. StrutsServlet


Correct Option: C
  1. SessionFacade

  2. Filter

  3. Front controller

  4. Back controller


Correct Option: C

To defeating browser cache?

  1. nocache=true

  2. cache=false

  3. nocachereuired=false

  4. None of the above


Correct Option: A

AI Explanation

To defeat browser cache, you can use the "nocache=true" option.

Explanation:

Option A) nocache=true - This option is correct because it instructs the browser to not cache the requested resource. By adding this parameter to the URL or request, the browser will always fetch the latest version of the resource from the server.

Option B) cache=false - This option is incorrect because there is no standard cache parameter called "cache" that can be set to false. This option does not exist.

Option C) nocacherequired=false - This option is incorrect because there is no standard cache parameter called "nocacherequired" that can be set to false. This option does not exist.

Option D) None of the above - This option is incorrect because option A, "nocache=true", is the correct option to defeat browser cache.

Therefore, the correct answer is A) nocache=true.

Which file contains java script for client side validation using validation framework in struts?

  1. validation.xml

  2. validator-rules.xml

  3. both files

  4. None


Correct Option: B
  1. Session , request

  2. Page, request, session

  3. Page, request, session, application

  4. request, session, application


Correct Option: A