posted 21 years ago
These are the two questions i have on implementing BodyTag Interface
1.Say,iam implementing BodyTag Interface,
and in my doStartTag() method, I return
EVAL_BODY_BUFFERED.Now, when the doAfterBody() method is called, will there be *any* difference if I return EVAL_BODY_AGAIN or EVAL_BODY_BUFFERED?will one effect Buffering and the other not?any such difference?
2.when implementing BodyTag Interface,if I have the following in doStarTag()/doEndTag()/doAfterBody() methods
case 1: pageContext.getOut().print("how are you?");
case 2: JSPWriter out = bodyContent.getEnclosingWriter() ;
out.print("how are you?") ;
bodyContent.writeOut(out);
Is there any difference in case 1 and case 2? Is it like in the first case iam writing to output directly instead of buffer and in the second case iam writing to buffer?and where does getPreviousOut() method come into picture?
Thanks to all.