A Buffer is a temporary storage area for data. The reader and writer classes provides character input and outout streams .The writer class is an output stream .It is an abstract class that cannot be directly instantiated.Creates a buffered character-output stream we use BufferedWriter class.
The FileReader and FileWriter classes are used to read and write 16 bit characters. However,many fie systems use 8 bit bytes. The I/O system of Java provides numerous classes to handle 8 bit bytes. The FileInputStream and FileOutputStream are the most frequently used classes to handle bytes.
The Reader and Writer class comprises various subclasses. These subclasses implement streams that can handle characters. The sub classes used to handle characters in file are FileReader and FileWriter. FileReader is used for reading characters from the file and FileWriter is used for writing character to the file.
The creation and utilization of a disk file involve various decisions to be made, such as an appropriate naming for the file, data type to be used, purpose of creating the file and method used in the creation of file.A Filename refers to a unique string of characters that facilitates easy identification of files on the disk.
Random Access File means that the data can be read from or written to random location in a file. In the File class, data is read from and written sequentially as continuous streams of data. The java.io package comprises a class known as RandomAccessFile that allows performing input/ output operations to any location within a file.