We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Caches are likely to reload entries using IO, so it would be nice if you could add support for async reloader functions in the Cache class.
Cache
All that's needed, I think, is to change this typedef:
typedef V LoaderFunc<K, V>(K key, V oldValue);
To this:
typedef FutureOr<V> LoaderFunc<K, V>(K key, V oldValue);
And then, fix the couple of locations invoking this function to allow for async behaviour (which seems pretty easy).
This would not be a breaking change due to Dart's great FutureOr type allowing functions to be either sync or not transparently.
FutureOr
The text was updated successfully, but these errors were encountered:
done on 0.4.0
Sorry, something went wrong.
No branches or pull requests
Caches are likely to reload entries using IO, so it would be nice if you could add support for async reloader functions in the
Cache
class.All that's needed, I think, is to change this typedef:
To this:
And then, fix the couple of locations invoking this function to allow for async behaviour (which seems pretty easy).
This would not be a breaking change due to Dart's great
FutureOr
type allowing functions to be either sync or not transparently.The text was updated successfully, but these errors were encountered: