Last week, we had the author of TDD for a Shopping Website LiveProject. Friday at 11am Ranch time, Steven Solomon will be hosting a live TDD session just for us. See for the agenda and registration link
Answer B is correct. Only when you return EVAL_BODY_INCLUDE your body will be processed. You return EVAL_BODY_PROCESSED when you need access to the body for your own manipulation. Check out the lifecycle chart on HFS page 533.
If we return EVAL_BODY_BUFFERED, a new buffer, an instance of body BodyContent is created and is available for further processing. we can simply get writer from the BodyContent object and print the content or make chages in the content.
As I understand it, C (EVAL_BODY_BUFFERED) is not really a correct answer because while it might output the body, that really depends on the code written to process the body. And if you go through the extra effort to write that code, chances are you're not going to just take the body and dump it into the output without at least some filtering.
If EVAL_BODY_BUFFERED is returned, and the custom action element is not empty, setBodyContent() is invoked, doInitBody() is invoked, the body is evaluated, doAfterBody() is invoked, and then, after zero or more iterations, doEnd- Tag() is invoked. If the custom action element is empty, only doStart() and doEndTag() are invoked.
Your buns are mine! But you can have this tiny ad:
free, earth-friendly heat - a kickstarter for putting coin in your pocket while saving the earth