Valid reasons to use a Schema rather than a DTD when defining an XML document include all of the following EXCEPT which?
A. Schemas are more widely used.
B. Schemas are capable of using namespaces.
C. Schemas are described with XML syntax.
D. Schemas are used to validate documents on content as well as data types.
正解:A
質問 2:
Which of the following is considered the best way to design a flexible API that does not require a servlet per activity?
A. Create a query string containing the activity name as a parameter. Let the servlet read the parameter to determine what must occur.
B. Use a servlet mapping to make requests with the same suffix. Change the prefix to the action and let the servlet read the whole URL to determine what is required.
C. Embed the activity name in a hidden field. Let the servlet read the field to determine what must occur.
正解:B
質問 3:
Consider the following Java code:
DataSource ds;
try {
ctx = new InitialContext(env);
ds = (DataSource) ctx.lookup("EmployeeDatabase");
}
catch (NamingException ne)
{
System.out.println("NamingException thrown!");
}
Connection con = ds.getConnection();
Which of the following actions are performed by the code above?
A. The code establishes a connection with a database.
B. The code releases a connection to a database.
C. The code utilizes a JDBC URL to locate a database.
D. The code utilizes JNDI.
正解:A,D
質問 4:
What method in the ServletContext could be used to get an attribute called times_Accessed from the servlet context?
A. getParameter(times_Accessed);
B. getParameter("times_Accessed");
C. getInitParameter("times_Accessed");
D. getAttribute("times_Accessed");
E. getAttribute(times_Accessed);
F. getInitParameter(times_Accessed);
正解:D
質問 5:
Which of the following is NOT a message transfer protocol?
A. SMTP
B. POP
C. IMAP
D. MIME
正解:D
質問 6:
In a JAX-RPC application, a SOAP "struct" maps to:
A. a vector.
B. a properties file.
C. an array.
D. a JavaBean class.
正解:D
質問 7:
The APIs used with JAXM applications are defined in which packages?
A. javax.xml.rpc
B. javax.xml.messaging
C. javax.xml.soap
D. javax.xml.registry
正解:B,C
質問 8:
At the top of a JSP the following directive appears:
<%@ page isErrorPage="true"%>
What does this indicate about the JSP?
A. That an exception will be thrown within the JSP
B. That if any errors or exceptions occur within the current JSP, they will be handled by another JSP
C. That it will have access to an implicit object called exception
D. That any exceptions thrown within the JSP should be ignored
正解:C
質問 9:
The following excerpt from a JSP is meant to display the following output:
The price without tax is: 100.0
The tax rate is: 0.15
The tax on your purchase is: 15.0
The total cost is: 115.0
Using only the line numbers outlined in the JSP excerpt, identify the three lines that need to be changed to allow for proper translation\compilation\display of the JSP. (Select three answers.) The JSP excerpt with the errors is:
<html>
<body>
1 <%! public double calculateTax(double price)
{return price * taxRate;}%>
2 <% double taxRate = 0.15;%>
3 <% public double calculateTotal(double price, double tax)
{return price + tax;}%>
4 <% double price = 100.00; %>
5 The price without tax is: <%= price %> <br>
6 The tax rate is: <%= taxRate %> <br>
7 The tax on your purchase is: <% calculateTax(price); %> <br>
The total cost is: <%= calculateTotal(price, calculateTax(price))%> <br>
</body>
</html>
A. Line 2
B. Line 7
C. Line 5
D. Line 3
E. Line 4
F. Line 6
G. Line 1
正解:A,B,D
1180 お客様のコメント





堀口** -
1D0-532の問題集には解説があるので時間短縮できて使いやすいです。