Given this fragment from a Java EE deployment descriptor:
341.<error-page>
342.<exception-type>java.lang.Throwable</exception-type>
343.<location>/mainError.jsp</location>
344.</error-page>
345.<error-page>
346.<exception-type>java.lang.ClassCastException</exception-type>
347.<location>/castError.jsp</location>
348.</error-page>
If the web application associated with the fragment above throws a ClassCastException.Which statement is true?()
A.The deployment descriptor is invalid.
B.The container invokes mainError.jsp.
C.The container invokes castError.jsp.
D.Neither mainError.jsp nor castError.jsp is invoked.
您可能感興趣的試卷
你可能感興趣的試題
Given a portion of a valid Java EE web application’s directory structure: MyApp |
|-- File1.html
|
|-- Directory1
||-- File2.html|
|-- META-INF
|-- File3.html
You want to know whether File1.html, File2.html, and/or File3.html will be directly accessible by your webclient’s browsers.
Which statement is true?()
A.All three files are directly accessible.
B.Only File1.html is directly accessible.
C.Only File2.html is directly accessible.
D.Only File3.html is directly accessible.
E.Only File1.html and File2.html are directly accessible.
A developer is designing a multi-tier web application and discovers a need to hide the details of establishingand maintaining remote communications from the client. In addition, because the business and resourcetiers are distributed, the application needs to minimize the inter-tier network traffic related to servicing clientrequests.
Which design patterns, working together, address these issues?()
A.Front Controller and Transfer Object
B.Front Controller and Service Locator
C.Business Delegate and Transfer Object
D.Business Delegate and Intercepting Filter
A developer is designing a multi-tier web application and discovers a need to log each incoming clientrequest.
Which two patterns, taken independently, provide a solution for this problem?()
A.Transfer Object
B.Service Locator
C.Front Controller
D.Intercepting Filter
E.Business Delegate
A developer is designing the presentation tier for a web application that relies on a complex session bean.The session bean is still being developed and the APIs for it are NOT finalized. Any changes to the sessionbean API directly impacts the development of the presentation tier.
Which design pattern provides a meansto manage the uncertainty in the API?()
A.View Helper
B.Front Controller
C.Composite View
D.Intercepting Filter
E.Business Delegate
最新試題
In which three directories, relative to a web application’s root, may a tag library descriptor file reside whendeployed directly into a web application?()
Your IT department is building a lightweight Front Controller servlet that invokes an application logic objectwith the interface:public interface ApplicationController {public String invoke(HttpServletRequest request)}The return value of this method indicates a symbolic name of the next view. From this name, the FrontController servlet looks up the JSP URL in a configuration table. This URL might be an absolute path or apath relative to the current request. Next, the Front Controller servlet must send the request to this JSP togenerate the view. Assume that the servlet variable request is assigned the current HttpServletRequestobject and the variable context is assigned the webapp’s ServletContext. Which code snippet of the FrontController servlet accomplishes this goal?()
Given a web application in which the request parameter productID contains a product identifier.Which twoEL expressions evaluate the value of the productID?()
Click the 'Select and Place' button.Place the events in the order they occur.
Click the ’Select and Place’ button.Place the events in the order they occur.
You are building a dating web site. The client’s date of birth is collected along with lots of other information.The Person class has a derived method, getAge():int, which returns the person’s age calculated from thedate of birth and today’s date. In one of your JSPs you need to print a special message to clients within theage group of 25 through 35.Which two EL code snippets will return true for this condition? ()
Click the ’Select and Place’ button.Place the events in the order they occur.
Which is a benefit of precompiling a JSP page?()
Click the 'Select and Place' button.Place the events in the order they occur.
Which element of a web application deployment descriptor element is required?()