answersLogoWhite

0


Best Answer

The BufferedReader class provides buffering to your Reader's. Buffering can speed up IO quite a bit. Rather than read one character at a time from the network or disk, you read a larger block at a time. This is typically much faster, especially for disk access and larger data amounts.

The main difference between BufferedReader and BufferedInputStream is that Reader's work on characters (text), wheres InputStream's works on raw bytes.

To add buffering to your Reader's simply wrap them in a BufferedReader. Here is how that looks:

Reader input = new BufferedReader(

new FileReader("c:\\data\\input-file.txt"));

User Avatar

Wiki User

15y ago
This answer is:
User Avatar
More answers
User Avatar

Wiki User

12y ago

An InputStreamReader is a bridge from byte streams to character streams: It reads bytes and decodes them into characters using a specified charset. The charset that it uses may be specified by name or may be given explicitly, or the platform's default charset may be accepted.

This answer is:
User Avatar

User Avatar

Wiki User

12y ago

An InputStreamReader is a bridge from byte streams to character streams: It reads bytes and decodes them into characters using a specified charset. The charset that it uses may be specified by name or may be given explicitly, or the platform's default charset may be accepted.

This answer is:
User Avatar

User Avatar

Wiki User

11y ago

is class for a java.lang.io package and DataInputStream used for a data input only.

any device you can input the data is very useful in java.

This answer is:
User Avatar

User Avatar

Wiki User

10y ago

BufferedReader class is used to perform I/O operations in Java.

This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What is the use of BufferedReader in Java programming?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Example of BufferedReader mothod in java programming?

import java.io.*; class gar { protected static void main()throws IOException { BufferedReader in=new BufferedReader(new InputStreamReader(System.in)); System.out.print("Enter a value: "); int a=Integer.parseInt(in.readLine()); } }


What is the meaning of bufferedreader?

BufferedReader br = new BufferedReader- can readline and close Java closes when the program terminates but you should always close the file.


What is a BufferedReader in java?

buffered is basically a way of creating an object


What programming language does minecraft use?

Java


What is BufferedReader in Java Programming?

BufferedReader is a class used to read text from charater-input stream and buffering characters which reads characters, arrays, and new lines. In general, each read request made using "Reader" class, causes a corresponding read request to be made of the underlying character or byte stream. It is therefore advisable to wrap a BufferedReader around any Reader whose read() operations may be costly, such as FileReaders and InputStreamReaders. For example, BufferedReader in = new BufferedReader(new FileReader("foo.in"));


What is parseInt in BufferedReader in java?

parseInt() interprets the next available token as an int.


Is it possible to use arrays when using the java programming language?

It is possible to use arrays when employing java programming language. There are many different series of programming choice that can be employed with various end results.


What is IOExeption in BufferedReader in java?

IOException is thrown when a general input output error occurs.


What programming language do most steam games use?

java


In java which package BufferReader class exist?

I believe you are asking about BufferedReader. It is in java.io package. java.io.BufferedReader;


Does the iPod use Java programming?

The iPod uses Objective-C as its programming language. You may install an additional app that can run Java on your iPod device, however.


What are the most popular programming languages that are use to develop websites?

Java