多項(xiàng)選擇題Which two statements are true about the security-related tags in a valid Java EE deployment descriptor?()

A.Every  tag must have at least one  tag.
B.A  tag can have many  tags.
C.A given  tag can apply to only one  tag.
D.A given  tag can contain from zero to many  tags.
E.It is possible to construct a valid  tag such that,for a given resource,no user rolescan access that resource.


您可能感興趣的試卷

你可能感興趣的試題

2.多項(xiàng)選擇題Which two are true concerning the objects available to developers creating tag files?()

A.The session object must be declared explicitly.
B.The request and response objects are available implicitly.
C.The output stream is available through the implicit outStream object.
D.The servlet context is available through the implicit servletContext object.
E.The JspContext for the tag file is available through the implicit jspContext object.

3.單項(xiàng)選擇題

You are creating a content management system (CMS) with a web application front-end. The JSP thatdisplays a given document in the CMS has the following general structure:
1. <%-- tag declaration --%>
2. <t:document>
...
11. <t:paragraph>... <t:citation docID=’xyz’ /> ...</t:paragraph> ...
99. </t:document>
The citation tag must store information in the document tag for the document tag to generate a referencesection at the end of the generated web page. The document tag handler follows the Classic tag model andthe citation tag handler follows the Simple tag model. Furthermore, the citation tag could also be embeddedin other custom tags that could have either the Classic or Simple tag handler model.
Which tag handlermethod allows the citation tag to access the document tag?()

A.public void doTag() {JspTag docTag = findAncestorWithClass(this, DocumentTag.class); ((DocumentTag)docTag).addCitation(this.docID);}
B.public void doStartTag() {JspTag docTag = findAncestorWithClass(this, DocumentTag.class); ((DocumentTag)docTag).addCitation(this.docID);}
C.public void doTag() {. Tag docTag = findAncestor(this, DocumentTag.class); . ((DocumentTag)docTag).addCitation(this.docID);. }
D.public void doStartTag() {. Tag docTag = findAncestor(this, DocumentTag.class); . ((DocumentTag)docTag).addCitation(this.docID);. }

4.多項(xiàng)選擇題

Given:
3.public class MyTagHandler extends TagSupport {
4.public int doStartTag() {
5.// insert code here
6.// return an int
7.}
8.// more code here
...
18.}
There is a single attribute foo in the session scope.
Which three code fragments,inserted independently atline 5,return the value of the attribute?()

A.Object o = pageContext.getAttribute("foo");
B.Object o = pageContext.findAttribute("foo");
C.Object o = pageContext.getAttribute("foo",PageContext.SESSION_SCOPE);
D.HttpSession s = pageContext.getSession();Object o = s.getAttribute("foo");

最新試題

A web application allows the HTML title banner to be set using a servlet context initialization parametercalled titleStr.Which two properly set the title in this scenario?()

題型:多項(xiàng)選擇題

Click the ’Select and Place’ button.Place the events in the order they occur.

題型:?jiǎn)柎痤}

Given a web application in which the request parameter productID contains a product identifier.Which twoEL expressions evaluate the value of the productID?()

題型:多項(xiàng)選擇題

Click the 'Select and Place' button.Place the events in the order they occur.

題型:?jiǎn)柎痤}

Click the ’Select and Place’ button.Place the events in the order they occur.

題型:?jiǎn)柎痤}

You are building a dating service web site. Part of the form to submit a client’s profile is a groupIIof radio buttons for the person’s hobbies:20.<input type=’radio’ name=’hobbyEnum’ value=’HIKING’>Hiking <br>21.<input type=’radio’ name=’hobbyEnum’ value=’SKIING’>Skiing <br>22.<input type=’radio’ name=’hobbyEnum’ value=’SCUBA’>SCUBA Diving23.<!-- and more options -->After the user submits this form, a confirmation screen is displayed with these hobbies listed. Assume thatan application-scoped variable, hobbies, holds a map between the Hobby enumerated type and the displayname.Which EL code snippet will display Nth element of the user’s selected hobbies?()

題型:?jiǎn)雾?xiàng)選擇題

Which is a benefit of precompiling a JSP page?()

題型:?jiǎn)雾?xiàng)選擇題

You need to create a JSP that generates some JavaScript code to populate an array of strings used on the client-side.Which JSP code snippet will create this array?()

題型:?jiǎn)雾?xiàng)選擇題

You are building your own layout mechanism by including dynamic content for the page’s header and footersections. The footer is always static, but the header generates the <title> tag that requires the page name tobe specified dynamically when the header is imported.Which JSP code snippet performs the import of theheader content?() 

題型:?jiǎn)雾?xiàng)選擇題

Which three are true about servlet filters?()

題型:多項(xiàng)選擇題