public interface KnownSizeEstimation
SizeEstimator
more accurate size estimation.
When a class extends it, SizeEstimator
will query the estimatedSize
first.
If estimatedSize
does not return None
, SizeEstimator
will use the returned size
as the size of the object. Otherwise, SizeEstimator
will do the estimation work.
The difference between a KnownSizeEstimation
and
SizeTracker
is that, a
SizeTracker
still uses SizeEstimator
to
estimate the size. However, a KnownSizeEstimation
can provide a better estimation without
using SizeEstimator
.Modifier and Type | Method and Description |
---|---|
long |
estimatedSize() |