findByPrefix<T> method

Future<Map<UserPrefKey, T?>> findByPrefix<T>(
  1. String prefix
)

Implementation

Future<Map<UserPrefKey, T?>> findByPrefix<T>(String prefix) async {
  final keys = await this.knownKeys;
  return <UserPrefKey, T?>{
    for (final key in keys)
      if (key.startsWith(prefix)) key: await get<T>(key),
  };
}