optional<T> static method

OptionalIO<T> optional<T>({
  1. T? seedValue,
  2. required String semantics,
  3. bool sync = true,
  4. bool isBehavior = true,
  5. bool acceptEmpty = true,
  6. bool isDistinct = false,
  7. bool printLog = true,
  8. FetchCallback<T, dynamic>? fetch,
  9. T? onReset()?,
  10. PersistConfig<T?>? persistConfig,
})

Implementation

static OptionalIO<T> optional<T>({
  T? seedValue,
  required String semantics,
  bool sync = true,
  bool isBehavior = true,
  bool acceptEmpty = true,
  bool isDistinct = false,
  bool printLog = true,
  FetchCallback<T, dynamic>? fetch,
  T? Function()? onReset,
  PersistConfig<T?>? persistConfig,
}) {
  return OptionalIO<T>(
    semantics: semantics,
    seedValue: seedValue,
    sync: sync,
    isBehavior: isBehavior,
    acceptEmpty: acceptEmpty,
    printLog: printLog,
    isDistinct: isDistinct,
    fetch: fetch,
    onReset: onReset,
    persistConfig: persistConfig,
  );
}