bugl
bugl
HomeLearnPatternsPathsSearchPremium
HomeLearnPatternsPaths

Loading lesson path

Learn/Java/Java Reference
Java•Java Reference

Java FileInputStream Methods

FileInputStream Methods

The FileInputStream class provides methods to read data (as bytes) from a file:

MethodDescriptionReturn Type
available()Returns the number of bytes that can be read without blockingint
close()Closes the stream and releases system resourcesvoid
read()Reads one byte of dataint
read()Reads bytes into an array (or part of an array)int
skip()Skips over and discards n bytes of datalong
getFD()Returns the file descriptor object associated with the streamFileDescriptor
getChannel()Returns the unique FileChannel object for this streamFileChannel

Related Pages

Java I/O Streams Tutorial

Previous

Java File Class Methods

Next

Java FileOutputStream Methods