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

doubt in custom tag mock ques 9 HFSJ page:553

 
Aditya Singh
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Question 9 on Custom tags has class extending BodyTagSupport, It asks what return values allow BodyContent to be processed?

It gives answer as EVAL_BODY_INCLUDE but EVAL_BODY_BUFFERED must also be correct if page 533 Life cycle is correct.

Thanks in advance.
 
Venkata Sunil Yadiki
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The eval_body_buffered only sends the body content to a buffer. But in order to process it you need to put up extra code. Where as in case of eval_body_include it automatically includes the body content.
 
Aditya Singh
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for reply, but is it possible to return EVAL_BODY_BUFFERED and then skip body processing? If no, then both are correct, right?
 
Pedro Erencia
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In my book the question asks which option would cause the body content to be _output_, not just processed. We can process the body with EVAL_BODY_BUFFERED then discard output buffer contents.
 
Aditya Singh
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thats right. Thanks, got it.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic