mirror of
https://gitlab.com/nkming2/nc-photos.git
synced 2025-03-25 00:14:42 +01:00
9 lines
299 B
Dart
9 lines
299 B
Dart
import 'package:np_platform_lock/src/raw_lock.dart';
|
|
|
|
class PlatformLock {
|
|
static Future<T> synchronized<T>(int lockId, Future<T> Function() fn) =>
|
|
RawLockInterface().synchronized(lockId, fn);
|
|
|
|
static Future<void> forceUnlock(int lockId) =>
|
|
RawLockInterface().forceUnlock(lockId);
|
|
}
|