remove method
Remove a ResourceContent associated with resource
.
See get for resource
description.
Implementation
ResourceContent? remove(Object? resource) {
if (resource == null) return null;
var resourceContent = ResourceContent.from(resource)!;
var cacheKey = _cacheKey(resourceContent);
if (cacheKey == null) return resourceContent;
var cached = _resources.remove(cacheKey);
return cached;
}