cache method

Future<void> cache(
  1. String key, {
  2. Duration? ttl,
})

Cache this map

Implementation

Future<void> cache(String key, {Duration? ttl}) async {
  await EaseXCache.cacheMap(key, this, ttl: ttl);
}