What is flush () in java?



What is flush () in java?..

Answer / Neha Singh

In Java, the `flush()` method is used to force the immediate flushing of any buffered output. It ensures that all output that has been written to a stream so far is actually sent to the output device.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Core Java Interview Questions

1.IN CASE OF DYNAMIC METHOD DISPATCH WHY WE USE REFERENCE VARIABLE,WE CAN USE THE DIFFERENT DEFINED OBJECT DIRECTLY TO ACCESS THE DATA MEMBER AND MEMBER FUNCTION OF THAT RESPECTIVE CLASS?WHAT IS THE MAIN FUNCTION OF "REFERENCE VARIABLE" HERE?

3 Answers   TCS,


If a class is declared without any access modifiers, where may the class be accessed in java programming?

1 Answers  


What is meant by class loader? How many types are there? When will we use them?

1 Answers  


Can we sort hashmap in java?

1 Answers  


Is there any limitation of using inheritance?

1 Answers  


What is a singleton puppy?

1 Answers  


What is the difference between final, finally and finalize() in java?

1 Answers  


Is it possible for yielded thread to get chance for its execution again ?

1 Answers  


If an application has multiple classes in it, is it okay to have a main method in more than one class?

1 Answers  


What is the use of generics? When was it added to the Java development Kit?

1 Answers   Impetus,


Which is faster call by value or call by reference?

1 Answers  


Is map ordered in java?

1 Answers  


Categories