cachesFor static method
Return a mapping of identifier to cache contents for all caches associated with client
.
Implementation
static Map<String, Map<Snowflake, Object?>> cachesFor(Nyxx client) {
final store = _stores[client];
if (store == null) {
return {};
}
final result = <String, Map<Snowflake, Object?>>{};
for (final entry in store.entries) {
(result[entry.key.identifier] ??= {})[entry.key.key] = entry.value.value;
}
return result;
}