All public methods are now checking if the file has been closed.