Alguém pode me explicar pq qui a resposta é a B e não a A.
Consider the following code for the doStartTag() method of a Tag:
public void doStartTag()
{
if(somecondition)
{
return IterationTag.EVAL_BODY_INCLUDE;
}
else
{
LINE 1: //forward the request to page2.jsp
}
}
Which of the following lines of code can be placed at LINE 1 above, so that the request can be forwarded to page2.jsp?
Select 1 correct option.
a RequestDispatcher rd = request.getRequestDispatcher(“page2.jsp”); rd.forward(request, response);
b pageContext.forward(“page2.jsp”);
c RequestDispatcher rd = pageContext.getRequestDispatcher(“page2.jsp”); rd.forward(request, response);
d request.forward(“page2.jsp”);
e None of these.