This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes JSP and the fly likes JspWriter vs PrintWriter Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "JspWriter vs PrintWriter" Watch "JspWriter vs PrintWriter" New topic

JspWriter vs PrintWriter

vara prasad
Ranch Hand

Joined: Dec 21, 2004
Posts: 47
what is difference between JspWriter and PrintWriter ?
Frederic Filiatrault
Ranch Hand

Joined: Jul 12, 2004
Posts: 69
Hi !

The first one begins with the letter "J-S-P" and the other begins with the letters "P-R-I-N-T"....

Ok, seriously. In case of a JSP File, you always have to use a JSPWriter because the output behavior depends if the page is buffered or not. Also, you can have a IOException (print, println in PrintWriter do not have one).

Here`s the link for more info:

JSPWriter Class

F.<br />SCJP, SCJD, SCWCD, SCBCD<br /> <br />Failure is not an option... It comes with the software bundle.
jQuery in Action, 2nd edition
subject: JspWriter vs PrintWriter
Similar Threads
Diff. PrintWriter versus JSPWriter
implicit objects question
JspWriter Vs PrintWriter
Outputting help