@Override
  public synchronized boolean isClosed() {
    return !CloseableReference.isValid(mBufRef);
  }
Gets the size of the ByteBuffer if it is valid. Otherwise, an exception is raised

@return the size of the ByteBuffer if it is not closed.
@throws {@link ClosedException}
imagepipeline/src/main/java/com/facebook/imagepipeline/memory/MemoryPooledByteBuffer.java