Yes, you got it.
As what you stated, java works like this:
1,
For input:
FileInputStream fis = new FileInputStream(f1)
or
FileInputStream fis = new
FileInputStream(¡°C:\\dir\\myfile¡±);
Attempts to open the file; may throw a FileNotFoundException
DataInputStream dis = new...