Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

EPractice Lab mock exam 5 , jsp:forward

 
Himai Minh
Ranch Hand
Posts: 1361
7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Which of the following statement is not true about the jsp:forward action?

a. If the page output is buffered, the buffer is cleared prior to forwarding.
b. If the page output is buffered and the buffer was flushed, the buffer is reset once again before forwarding.
c. If the page output was unbuffered and anything has been written to it, an attempt to forward the request will result in an IllegalStateException.
Choice B is correct
If the page output is buffered and the buffer was flushed, an attempt to forward the request will result in an IllegalStateException.


I don't think c is always true.
If the output is committed, an attempt to forward will throw IllegalStateException. But if the output is not committed, the forward will not throw this exception.
The statement in c does not mention if the output is committed or not committed yet.
 
Frits Walraven
Creator of Enthuware JWS+ V6
Saloon Keeper
Pie
Posts: 2536
113
Android Chrome Eclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The statement in c does not mention if the output is committed or not committed yet.

Unbuffered means that everything writen to the page output is immediately flushed (committed).
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic