java.io

Interface Closeable

public interface Closeable

A Closeable class represents a stream of data, which can be closed when it is no longer needed. Closing a stream allows the resources it uses to be freed for an alternate use.

Since: 1.5

Method Summary
voidclose()
Closes the stream represented by this class, thus freeing system resources.

Method Detail

close

public void close()
Closes the stream represented by this class, thus freeing system resources. In that case that the stream is already in the closed state, this method has no effect.

Throws: IOException if an I/O error occurs in closing.