Thursday, January 13, 2011

Article | Packages Java : import java.io.*;

There are so many features in java.io
Which includes the BufferedReader Writer etc.
BufferedReader

Hierarchy for Output Classes





- Writer, streams buffers and output streams.



Reading from the Java Console.



- Scanner class encapsulates all this reading and writing.



Alternative coding



BufferedReader br = new BufferedReader



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



System.in Object





- Wrapping in a hierarchy just to read input from the user.



- Whatever the users types the return type will always be a string because of the wrapping.







java.io package



- Reader, streams and buffers and readers.

- You can read and write objects but only if they were read and written as objects in the first place.





Loading...

Comments :

0 comments to “ Packages Java : import java.io.*; ”

Post a Comment

Enter any comments

Followers