customAdapter<T> static method

Prf<T> customAdapter<T>(
  1. String key, {
  2. required PrfAdapter<T> adapter,
  3. T? defaultValue,
})

Creates a new preference using a custom adapter.

Implementation

static Prf<T> customAdapter<T>(
  String key, {
  required PrfAdapter<T> adapter,
  T? defaultValue,
}) {
  return Prf._withAdapter(
    key,
    adapter: adapter,
    defaultValue: defaultValue,
  );
}