Solved

difference between System.out.write and output.write

Posted on 2010-11-22
4
694 Views
Last Modified: 2012-05-10
I want to make sure that my understanding about  the difference between System.out.write and output.write is correct.

System.out.write(buffer, 0, bufferCount);  will write the contents of buffer upto bufferCount to the console
whereas
 output.write(buffer, 0, bufferCount);  will wrtie teh content of buffer upto bufferCount  to the  outputStream (assuming output is outputStream).

Please correct me if I'm wrong
0
Comment
Question by:javaCaravan0
  • 3
4 Comments
 
LVL 86

Expert Comment

by:CEHJ
ID: 34187231
You don't say what type 'output' is ...
0
 

Author Comment

by:javaCaravan0
ID: 34187290
output type is servletOutputStream
0
 
LVL 86

Accepted Solution

by:
CEHJ earned 125 total points
ID: 34187475
Your analysis is right
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 34362396
:)
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

Suggested Solutions

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
Viewers will learn about the regular for loop in Java and how to use it. Definition: Break the for loop down into 3 parts: Syntax when using for loops: Example using a for loop:
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now