Win a copy of Svelte and Sapper in Action this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

Question from Head First book chapter 10

 
Ranch Hand
Posts: 105
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator



Assume that the tag has been properly configured to allow body content.

Which, if inserted at line 12, would cause the JSP code

<mytags:mytag>BodyContent</mytags:mytag> to ouput BodyContent?

A. return SKIP_BODY;

B. return EVAL_BODY_INCLUDE;

C. return EVAL_BODY_BUFFERED;

D. return BODY_CONTENT;


Answer: B

Why not B and C?

Thanks in advance.
 
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The question is : Which would cause the JSP code <mytags:mytag>BodyContent</mytags:mytag> to ouput BodyContent?
Returning EVAL_BODY_BUFFERED will not cause it to output the content of the body, it will store it in a buffer, and you will be responsible for outputting its content.

I find this question a bit disturbing, because we could say that the body content is ouput in a buffer, but I think they mean "output in the web browser"...
 
Pawan Arora
Ranch Hand
Posts: 105
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks, it's cleared now.
 
    Bookmark Topic Watch Topic
  • New Topic