From 815f1809a5854b14ecd020615d1a2ef0144aaa30 Mon Sep 17 00:00:00 2001 From: Vadim <44135514+vodemn@users.noreply.github.com> Date: Tue, 29 Oct 2024 19:41:50 +0100 Subject: [PATCH] added iap stub methods --- iap/lib/m3_lightmeter_iap.dart | 1 + iap/lib/src/data/films_storage_service.dart | 32 +++++++++++++++++++++ iap/lib/src/data/iap_storage_service.dart | 6 ---- 3 files changed, 33 insertions(+), 6 deletions(-) create mode 100644 iap/lib/src/data/films_storage_service.dart diff --git a/iap/lib/m3_lightmeter_iap.dart b/iap/lib/m3_lightmeter_iap.dart index 43e69aa..003b0da 100644 --- a/iap/lib/m3_lightmeter_iap.dart +++ b/iap/lib/m3_lightmeter_iap.dart @@ -5,5 +5,6 @@ import 'package:m3_lightmeter_resources/m3_lightmeter_resources.dart'; export 'src/data/models/iap_product.dart'; export 'src/providers/iap_products_provider.dart'; export 'src/data/iap_storage_service.dart'; +export 'src/data/films_storage_service.dart'; const List films = []; diff --git a/iap/lib/src/data/films_storage_service.dart b/iap/lib/src/data/films_storage_service.dart new file mode 100644 index 0000000..ca2b578 --- /dev/null +++ b/iap/lib/src/data/films_storage_service.dart @@ -0,0 +1,32 @@ +import 'package:flutter/foundation.dart'; +import 'package:m3_lightmeter_resources/m3_lightmeter_resources.dart'; + +typedef SelectableFilm = ({T film, bool isUsed}); + +class FilmsStorageService { + FilmsStorageService(); + + Future init() async {} + + @visibleForTesting + Future createTable(dynamic _) async {} + + String get selectedFilmId => ''; + set selectedFilmId(String id) {} + + Future addFilm(FilmExponential _) async {} + + Future updateFilm(FilmExponential _) async {} + + Future toggleFilm(Film _, bool __) async {} + + Future deleteFilm(FilmExponential _) async {} + + Future>> getPredefinedFilms() async { + return const {}; + } + + Future>> getCustomFilms() async { + return const {}; + } +} diff --git a/iap/lib/src/data/iap_storage_service.dart b/iap/lib/src/data/iap_storage_service.dart index 9bc58d0..14eaa4b 100644 --- a/iap/lib/src/data/iap_storage_service.dart +++ b/iap/lib/src/data/iap_storage_service.dart @@ -8,10 +8,4 @@ class IAPStorageService { List get equipmentProfiles => []; set equipmentProfiles(List profiles) {} - - Film get selectedFilm => const FilmStub(); - set selectedFilm(Film value) {} - - List get filmsInUse => []; - set filmsInUse(List profiles) {} }