JAVA IO Streams
What is an I/O STREAM?
Input Stream
Output Stream
Characterization of STREAM’s
- Java IO Streams can be primarily characterized as BYTE Streams and CHARACTER Streams.
- Byte Streams – Byte Streams directly read’s bytes from the Source or write’s bytes to the Destination. The super types of Byte Streams are InputStream and OutputStream.
- Character Streams – Character Streams read’s Character from the Source or write’s Character to the Destination. Character Streams internally converts Unicode to Local Character Set (depends on the Java Locale provided). The super types of Character Streams are Reader and Writer.
- Java IO Streams can also be characterized as Source Facing Streams and Stream Facing Streams.
- Source Facing Streams – Source Facing Streams are Streams which directly either reads or writes into the source or destination. Examples of Source facing Stream are FileInputStream, FileOutputStream, ArrayInputStream and ArrayOutputStream etc.
- Stream Facing Streams – Stream Facing Streams are Streams which depends upon intermediate input or output streams to read or write data. Example of Stream Facing Streams are BufferedInputStream, ObjectStream etc.
JAVA IO Table
<< Java IO Stream MENU | Major Java IO Streams >> |
No comments:
Post a Comment