code: @Override
      public void close() throws IOException {
          try {
              if (reference != null) {
                  closer.close(reference);
              }
          } catch (Exception e) {
              throw new IOException(e);
          } finally {
              this.wasClosed = true;
          }
      }
docs: Close (or free) the reference
  
  @throws IOException if any exception occurs