- File Copying
- Semantics of File copying – FileInputStream and FileOutputStream
- Skipping a few bytes in a file and reading
- File copying – Using FileReader & FileWriter
- Reading data types using DataInputStream and DataOutputStream
- Merging of files – SequenceInputStream
- Reading and writing sequentially and randomly – Using RandomAccessFile
Filter Streams – 1. FilterInputStream and FilterOutputStream 2. FilterReader and FilterWriter
Wrapper Streams: InputStreamReader and OutputStreamWriter
Keyboard Reading
Reading and writing to arrays and strings
- Reading and writing into byte arrays: 1. ByteArrayInputStream 2.ByteArrayOutputStream
- Reading and writing to char arrays: 1. CharArrayReader 2. CharArrayWriter
- Reading strings using StringBufferInputStream: 1. StringReader 2. StringWriter
Special Programs
- To find number of lines in a file
- Adding line numbers to a file: 1. LineNumberInputStream 2. LineNumberReader
- PrintStream vs PrintWriter
- Byte streams vs Character streams
- Rereading a file – Using markSupported(), mark() & reset()
- Pushing out Character – PushbackReader
- Piping data between two streams – 1. PipedInputStream and PipedOutputStream 2. PipedReader and PipedWriter
- Retrieving metadata of a file – File class
- Changing file properties – File class
- Formatting Data – PrintWriter
- Chaining or linking of streams
- Closeable and Flushable interfaces
- PrintStream
- Tokenizing a stream – StreamTokenizer
- Checking for tokens in file reading – using Scanner
- What is System.out.println()?
Performance tips in file copying
- Performance drawbacks in file copying
- Peak performance with 1. BufferedInputStream and BufferedOutputStream 2. BufferedReader and BufferedWriter
- Performance in file copying using DataInputStream and DataOutputStream