delete<T extends Cacheable> method
void
delete<
T extends Cacheable>({ - String? key,
- Cacheable? data,
})
override
Implementation
@override
void delete<T extends Cacheable>({String? key, Cacheable? data}) {
if (T == DeliveryStatus || data is DeliveryStatus) {
deliveryStatus = null;
} else if (T == TypingStatus || data is TypingStatus) {
typingStatus.remove(key);
} else if (T == ReadStatus || data is ReadStatus) {
readStatus.remove(key);
} else if (T == CachedDataMap || data is CachedDataMap) {
cachedMetaData = null;
}
//channel should be delete itself
}