maximumByteSize property
int
get
maximumByteSize
Maximum number of compiled SVG bytes to retain. Defaults to 32 MiB.
The limit applies to completed cache entries; an in-flight decode and any widget currently painting the SVG may use additional memory.
Implementation
int get maximumByteSize => _maximumByteSize;
set
maximumByteSize
(int value)
Sets the completed-entry byte budget and immediately evicts LRU entries if necessary. Zero disables caching without preventing SVG rendering.
Implementation
set maximumByteSize(int value) {
assert(value >= 0);
if (value == maximumByteSize) {
return;
}
_maximumByteSize = value;
if (value == 0) {
clear();
} else {
_trim();
}
}