I was reading a tutorial for using I/O streams in java and stumbled upon the following code for inputstream:
InputStream input = new FileInputStream("c:\\data\\input-file.txt");
int data = input.read();
while(data != -1){
data = input.read();
}
The tutorial mentions that InputStream returns only one byte at a time. So if I want to receive more bytes at a time, is that possible using a different method call?