TCacheManager<T> constructor
Creates a new instance of TCacheManager.
cleaningInterval
: The interval at which the cache should be cleaned. Defaults to 1 minute.maxSize
: The maximum number of items the cache can hold. Defaults to 100.debugLabel
: A label to be used for debugging purposes.
Implementation
TCacheManager({
Duration? cleaningInterval,
int? maxSize,
this.debugLabel,
}) : _cleaningInterval = cleaningInterval ?? const Duration(minutes: 1),
_maxSize = maxSize ?? 100;