A library for managing asynchronous processes inspired by the Go sync package.
- Mutex & ReadWriteMutex
Unless otherwise mentioned at the top of a file, all code is licensed under the MIT license as found in the LICENSE file.
- Initial version.
Use this package as a library
1. Depend on it
Add this to your package's pubspec.yaml file:
dependencies: sync: ^0.2.0
2. Install it
You can install packages from the command line:
$ pub get
$ flutter pub get
Alternatively, your editor might support
pub get or
flutter pub get.
Check the docs for your editor to learn more.
3. Import it
Now in your Dart code, you can use:
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
We analyzed this package on Jan 27, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:
- Dart: 2.7.1
- pana: 0.13.4
lib/semaphore.dart. (-2.96 points)
lib/semaphore.dart reported 6 hints, including:
line 11 col 33: Unnecessary new keyword.
line 15 col 13: Unnecessary new keyword.
line 18 col 13: Unnecessary new keyword.
line 25 col 21: Unnecessary new keyword.
line 38 col 13: Unnecessary new keyword.
lib/read_write_mutex.dart. (-1.99 points)
lib/read_write_mutex.dart reported 4 hints:
line 17 col 31: Unnecessary new keyword.
line 60 col 7: Unnecessary new keyword.
line 94 col 13: Unnecessary new keyword.
line 114 col 18: Unnecessary new keyword.
lib/waitgroup.dart. (-1.49 points)
lib/waitgroup.dart reported 3 hints:
line 21 col 13: Unnecessary new keyword.
line 35 col 14: Unnecessary new keyword.
line 38 col 20: Unnecessary new keyword.
lib/mutex.dart. (-0.50 points)
lib/mutex.dart reported 1 hint:
line 26 col 35: Unnecessary new keyword.
Package is getting outdated. (-29.86 points)
The package was last published 67 weeks ago.
Maintain an example. (-10 points)
Create a short demo in the
example/ directory to show how to use this package.
Common filename patterns include
sync.dart. Packages with multiple examples should provide
For more information see the pub package layout conventions.
|Dart SDK||>=1.0.0 <3.0.0|