@Override
  public synchronized void close() throws IOException {
    if (isOpen()) {
      fileSystemState.unregister(this);
      file.closed();

      // file is set to null here and only here
      file = null;
    }
  }
{@link InputStream} for reading from a file's {@link RegularFile}.

@author Colin Decker
jimfs/src/main/java/com/google/common/jimfs/JimfsInputStream.java