The java.io
package in Java provides classes and interfaces for performing input and output (I/O) operations, such as reading and writing data to and from files, byte arrays, and other data streams. This package is crucial for handling data from various sources.
- BufferedInputStream : The class is responsible for adding the functionality to other input streams. The class is declared as:public class BufferedInputStream extends FilterInputStream The class extends the FilterInputStream class.
- BufferedOutputStream: The class is responsible for the implementation of Buffered output stream. The class is declared as: public class BufferedOutputStream
extends FilterOutputStream The class extends the FilterInputStream class. - BufferedReader : The class reads the texts from the char input stream. The class is declared as: public class BufferedReader extends Reader The class extends the Reader class.
- BufferedWriter: The class write the texts to the char input stream. The class is declared as:
public class BufferedWriter
extends Writer
The class extends the Writer class. - ByteArrayInputStream: The class is responsible for reading of data form byte array. The class is declared as:
public class ByteArrayInputStream
extends InputStream
The class extends the InputStreamclass - ByteArrayOutputStream: The class is responsible for writing of data into byte array. The class is declared as:
public class ByteArrayOutputStream
extends OutputStream
The class extends the OutputStream class. - CharArrayReader: The class is responsible for the implementation of character buffer to be further used as character input stream. The class is declared as:
public class CharArrayReader extends Reader
The class extends the Reader class. - CharArrayWriter: The class is responsible for the implementation of character buffer to be further used as character output stream. The class is declared as:
public class CharOutputWriter extends Writer
The class extends the Writer class. - Console: All theassociated console devices can be accessed using this class. The class is declared as:
public final class Console extends Object
implements Flushable
The class extends the Object class. - DataInputStream: The stream is used for reading the java data types which are primitive. The class is declared as:
public class DataInputStream extends FilterInputStream implements DataInputThe class extends the FilterInputStreamclass - DataOutputStream: The stream is used for writing the java data types which are primitive. The class is declared as:
public class DataOutputStream extends FilterOutputStream implements DataOutput
The class extends the FilterOutputStream class - File: The class provides a representation of the file path names. The class is declared as:
public class File extends Object implements Serializable, Comparable<File>
The class extends the Object class - FileDescriptor: It is mainly used for creation of file input and output streams. The class is declared as:
public final class FileDescriptor
extends Object
he class extends the Object class - FileInputStream: The class is used to retrieve the input bytes from a file system. The class is declared as:
public class FileInputStream extends InputStream
The class extends the InputStream class - FileOutputStream: It is a parent class of all the output stream classes. The class is declared as:
public class FileOutputStream extends OutputStream
The class extends the OutputStream class - FilePermission:All the access related issues are handled by the class. The class is declared as:
public final class FilePermission extends Permission
implements Serializable
The class extends the Permisison class - FileReader:The class is used for reading data from the character files. The class is declared as:
public class FileReader extends InputStreamReader
The class extends the InputStreamReaderclass - FileWriter:The class is used for writing data into the character files. The class is declared as:
public class FileWriter extends OutputStreamWriter
The class extends the OutputStreamWriter class - FilterInputStream:The class is a parent class of all the ones which filter the input streams. The class is declared as:
public class FilterInputStream
extends InputStream
The class extends the InputStreamclass. - FilterOutputStream: The class is a parent class of all the ones which filter the output streams. The class is declared as:
public class FilterOutputStream
extends OutputStream
The class extends the OutputStream class. - FilterReader: The class is an abstract class which is responsible for reading from the filtered char streams. The class is declared as:
public abstract class FilterReader extends Reader
The class extends the Reader class. - FilterWriter: The class is an abstract class which is responsible for writing into the filtered char streams. The class is declared as:
public abstract class FilterWriter extends Writer
The class extends the Writer class. - InputStream: The class is the parent class of all the input stream classes. The class is declared as:
public abstract class InputStream extends Object
implements Closeable
The class extends the Object class. - InputStreamReader: The class reads from the byte stream files and decodes it into the char stream. The class is declared as:
public class InputStreamReader extends Reader
The class extends the Reader class. - LineNumberInputStream: The class is based on the assumption that bytes represent characters. The class is declared as:
public class LineNumberInputStream
extends FilterInputStream
The class extends theFilterInputStream class. - LineNumberReader: It keeps track of the line numbers. The class is declared as:
public class LineNumberReader extends BufferedReader
The class extends theBufferedReaderclass. - ObjectInputStream: he data or objects which were written using the ObjectInputStream is deserialized by the class. The class is declared as:
public class ObjectInputStream extends InputStream implements ObjectInput, ObjectStreamConstants
The class extends theInputStream class. - ObjectInputStream.GetField: The fields which have been successfully read from the various input streams, access to them is provided by the class. The class is declared as:
public abstract static class ObjectInputStream.GetField extends Object
The class extends theObjectclass. - ObjectOutputStream: Objects and data types are written to the output stream using this class. The class is declared as:
public class ObjectOutputStream extends OutputStream
implements ObjectOutput, ObjectStreamConstants
The class extends theOutputStreamclass. - ObjectOutputStream.PutField: There are fields which are written to the output stream, class provides access to them. The class is declared as:
public abstract static class ObjectOutputStream.PutField
extends Object The class extends theObjectclass - ObjectStreamClass: It is the class which is responsible for serializing the classes. The class is declared as:
public class ObjectStreamClass
extends Object
implements Serializable
The class extends theObjectclass. - ObjectStreamField: There are fields which are to be written in the object output, the class provides access to them. The class is declared as:
public abstract static class ObjectOutputStream.PutField
extends Object
The class extends theObjectclass. - OutputStream: The class is the parents of all the output stream classes. The class is declared as:
public abstract class OutputStream
extends Object
implements Closeable, Flushable
The class extends theObjectclass - .OutputStreamWriter: The class is responsible for interchanging of components written in char stream to the byte stream. The class is declared as:
public class OutputStreamWriter
extends Writer
The class extends theWriterclass. - PipedInputStream: It is used for reading data from the piped input streams. The class is declared as:
public class PipedInputStream
extends InputStream
The class extends theInputStreamclass. - PipedOutputStream: The class is used for writing the data into piped output streams. The class is declared as:
public class PipedOutputStream
extends OutputStream
The class extends theOutputStream class. - PipedReader: The class acts as an input stream for reading the piped characters. The class is declared as:
public class PipedReader
extends Reader
The class extends theReader class. - PipedWriter: The class is used for writing characters into the piped output. The class is declared as:
public class PrintWriter
extends Writer
The class extends theWriter class. - PrintStream: The class is used for reading the output stream files. The class is declared as:
public class PrintStream extends FilterOutputStream implements Appendable, Closeable
The class extends theFilterOutputStream class. - PrintWriter: The class is used for printing of objects into outputs in text form. The class is declared as:
public class PrintWriter
extends Writer
The class extends theWriter class. - PushbackInputStream: It is used to add additional properties to the input stream. It can unread a byte value. The class is declared as:
public class PushbackInputStream extends FilterInputStream
The class extends theFilterInputStream class. - PushbackReader: It is used to unread a char value. The class is declared as:
public class PushbackReader extends FilterReader
The class extends theFilterReader class. - RandomAccessFile: It is used to access the file in consideration randomly. The class is declared as:
public class RandomAccessFile extends Object
implements DataOutput, DataInput, Closeable
The class extends theObject class. - Reader: The class is used for reading data from the character streams. The class is declared as:
public abstract class Reader extends Object
implements Readable, Closeable
The class extends theObject class. - SequenceInputStream: The concatenation of various input streams, logical is reflected by this class. The class is declared as:
public class SequenceInputStream
extends InputStream
The class extends theInputStream class. - SerializablePermission: The class is used for providing permissions related to serializing. The class is declared as:
public final class SerializablePermission
extends BasicPermission
The class extends theBasicPermission class - StreamTokenizer: The class is used for reading the input streams in form of tokens. The class is declared as:
public class StreamTokenizer
extends Object
The class extends the Object class. - StringBufferInputStream: It was originally designed for conversion of characters into bytes. The class is declared as:
public class StringBufferInputStream
extends InputStream
The class extends theInputStream class. - StringReader: The class is used for reading the strings from the file. The class is declared as:
public class StringReader
extends Reader
The class extends theReader class. - StringWriter: The class is used for writing strings to the file. The class is declared as:
public class StringWriter extends Writer
he class extends the Writer class. - Writer: The class is used for writing characters to the output stream. The class is declared as:
public abstract class Writer
extends Object
implements Appendable, Closeable, Flushable
The class extends the Object class.