Files
umbrix/lib/domain/rules/geo_assets_repository.dart
2023-11-17 23:44:32 +03:30

17 lines
558 B
Dart

import 'package:fpdart/fpdart.dart';
import 'package:hiddify/domain/rules/geo_asset.dart';
import 'package:hiddify/domain/rules/geo_asset_failure.dart';
abstract interface class GeoAssetsRepository {
TaskEither<GeoAssetFailure, ({GeoAsset geoip, GeoAsset geosite})>
getActivePair();
Stream<Either<GeoAssetFailure, List<GeoAssetWithFileSize>>> watchAll();
TaskEither<GeoAssetFailure, Unit> update(GeoAsset geoAsset);
TaskEither<GeoAssetFailure, Unit> markAsActive(GeoAsset geoAsset);
TaskEither<GeoAssetFailure, Unit> addRecommended();
}