Java SCWCD, OCWCD Test 2 - SCWCD Quiz | OCWCD Quiz | OCWCD Online Test
Finish Quiz
0 of 20 questions completed
Questions:
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
Information
Java SCWCD, OCWCD Test 2 – SCWCD Quiz | OCWCD Online Quiz | OCWCD Online Test. Let’s play scwcd or ocwcd online test or quiz that will help you to clear your concepts and will prepare you for the interviews. , Free Java SCWCD/OCWCD Quiz, Online Java, online Test Quiz 2. Java SCWCD/OCWCD Quiz 2 Question and Answers 2024. Java online Test Quiz 2. Java SCWCD/OCWCD Quiz 2 Free Mock Test 2024. Java SCWCD/OCWCD Quiz 2 Question and Answers in PDF. The Java online mock test paper is free for all students. Spring Online is very useful for exam preparation and getting for Rank. Java SCWCD/OCWCD Quiz 2 Question and Answers in English. Java SCWCD/OCWCD Mock test for topic via SCWCD/OCWCD Mode. Here we are providing Java SCWCD/OCWCD Quiz in English Now Test your self for “SCWCD/OCWCD Online Quiz in English” Exam by using below quiz…
This paper has 20 questions.
Time allowed is 25 minutes.
The Java SCWCD/OCWCD Mock Test is Very helpful for all students. Now Scroll down below n click on “Start Quiz” or “Start Test” and Test yourself.
You have already completed the quiz before. Hence you can not start it again.
Quiz is loading...
You must sign in or sign up to start the quiz.
You have to finish following quiz, to start this quiz:
Results
0 of 20 questions answered correctly
Your time:
Time has elapsed
You have reached 0 of 0 points, (0)
Average score |
|
Your score |
|
Categories
- Not categorized 0%
Pos. | Name | Entered on | Points | Result |
---|---|---|---|---|
Table is loading | ||||
No data available | ||||
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- Answered
- Review
-
Question 1 of 20
1. Question
The Squeaky Bean company has decided to port their web application to a new J2EE 1.4 container. While reviewing the application, a developer realizes that in multiple places within the current application, nearly duplicate code exists that finds enterprise beans. Which pattern should be used to eliminate this duplicate code?
Correct
Incorrect
-
Question 2 of 20
2. Question
Given an EL function foo, in namespace func, that requires a long as a parameter and returns a Map, which two are valid invocations of function foo?
Correct
Incorrect
-
Question 3 of 20
3. Question
Squeaky Beans Inc. hired an outside consultant to develop their web application. To finish the job quickly, the consultant created several dozen JSP pages that directly communicate with the database. The Squeaky business team has since purchased a set of business objects to model their system, and the Squeaky developer charged with maintaining the web application must now refactor all the JSPs to work with the new system. Which pattern can the developer use to solve this problem?
Correct
Incorrect
-
Question 4 of 20
4. Question
Which three web application deployment descriptor elements allow web components to gain references to resources or EJB components?
Correct
Incorrect
-
Question 5 of 20
5. Question
Which EL expression evaluates to the request URI?
Correct
Incorrect
-
Question 6 of 20
6. Question
Which three are valid URL mappings to a servlet in a web deployment descriptor?
Correct
Incorrect
-
Question 7 of 20
7. Question
Which one JSTL URL-related tags perform URL rewriting?
Correct
Incorrect
-
Question 8 of 20
8. Question
Which three are true about TLD files?
Correct
Incorrect
-
Question 9 of 20
9. Question
A developer has used this code within a servlet:
62. if(request.isUserInRole(“vip”)) {
63. // VIP-related logic here
64. }
What else must the developer do to ensure that the intended security goal is achieved?Correct
Incorrect
-
Question 10 of 20
10. Question
Which two actions protect a resource file from direct HTTP access within a web application?
Correct
Incorrect
-
Question 11 of 20
11. Question
Given: 1. <% int[] nums = {42,420,4200}; 2. request.setAttribute(“foo”, nums); %> 3. ${5 + 3 lt 6} 4. ${requestScope[‘foo’][0] ne 10 div 0} 5. ${10 div 0} What is the result?
Correct
Incorrect
-
Question 12 of 20
12. Question
Given:
3. class MyServlet extends HttpServlet {
4. public void doPut(HttpServletRequest req, HttpServletResponse resp) throws
ServletException, IOException {
5. // servlet code here …
26. }
27. }
If the DD contains a single security constraint associated with MyServlet and its only
<http-method> tags and <auth-constraint> tags are:
<http-method>GET</http-method>
<http-method>PUT</http-method>
<auth-constraint>Admin</auth-constraint>
Which four requests would be allowed by the container?Correct
Incorrect
-
Question 13 of 20
13. Question
A developer is designing a web application that must verify for each request: The originating request is from a trusted network. The client has a valid session. The client has been authenticated. Which design pattern provides a solution in this situation?
Correct
Incorrect
-
Question 14 of 20
14. Question
A custom JSP tag must be able to support an arbitrary number of attributes whose names are unknown when the tag class is designed. Which two are true?
Correct
Incorrect
-
Question 15 of 20
15. Question
Which one about WAR files are true?
Correct
Incorrect
-
Question 16 of 20
16. Question
Given this fragment in a servlet: 23. if(req.isUserInRole(“Admin”)) { 24. // do stuff 25. } And the following fragment from the related Java EE deployment descriptor: 812. 813. Admin 814. Administrator 815. 900. 901. Admin 902. Administrator 903. What is the result?
Correct
Incorrect
-
Question 17 of 20
17. Question
Given that http://www.example.com/SCWCDtestApp is a validly deployed Java EE web application and that all of the JSP files specified in the requests below exist in the locations specified. Which two requests, issued from a browser, will return an HTTP 404 error?
Correct
Incorrect
-
Question 18 of 20
18. Question
A developer has created a special servlet that is responsible for generating XML content that is sent to a data warehousing subsystem. This subsystem uses HTTP to request these large data files, which are compressed by the servlet to save internal network bandwidth. The developer has received a request from management to create several more of these data warehousing servlets. The developer is about to copy and paste the compression code into each new servlet. Which design pattern can consolidate this compression code to be used by all of the data warehousing servlets?
Correct
Incorrect
-
Question 19 of 20
19. Question
Given an HttpServletRequest request and HttpServletResponse response, which sets a cookie “username” with the value “joe” in a servlet?
Correct
Incorrect
-
Question 20 of 20
20. Question
QUESTION: 133
Given the web application deployment descriptor elements:
11. <filter>
12. <filter-name>ParamAdder</filter-name>
13. <filter-class>com.example.ParamAdder</filter-class>
14. </filter>
…
24. <filter-mapping>
25. <filter-name>ParamAdder</filter-name>
26. <servlet-name>MyServlet</servlet-name>
27. <!– insert element here –>
28. </filter-mapping>
Which element, inserted at line 27, causes the ParamAdder filter to be applied when
MyServlet is invoked by another servlet using the RequestDispatcher.include
method?Correct
Incorrect