flutter_fit_utils library

Classes

FirestoreCollection
Implementation of Repository. Manages data inside a Firebase Firestore collection.
FirestoreService<T extends Modelable>
Service for managing a FirestoreCollection repository.
Model
Template class for encapsulating data.
Modelable
Interface that can transform a class into a Model.
RemoteConfigRepository
Implementation of Repository. Manages data inside a Firebase Remote Config parameter.
RemoteConfigService<T extends Modelable>
Service for managing a RemoteConfigRepository.
Repository
Base data repository. Can perform the basic CRUD operations.
Service<T extends Modelable>
Manager service for data of type T.
SharedPreferenceRepository
Implementation of Repository. Manages data inside a SharedPreference collection.
SharedPreferenceService<T extends Modelable>
Service for managing a SharedPreferenceRepository.
Where

Extensions

DurationUtils on Duration
Extension of the Duration class.
FitColorExtension on Color
Extension of the Color class.
FitDateTimeExtension on DateTime
Extension of the DateTime class.
FitDoubleExtension on double
Extension of the double type.
FitModelableExtension on List<Modelable>
Extension of the List<Modelable> type.
FitStringExtension on String
Extension of the String class.

Functions

getDayIndex(String day) int
Returns the index of a day throughout the week. The day input is expected to be from FitDateTimeExtension.getDate(). The index 0 is considered to be monday.
getToday() String
Returns the weekday of DateTime.now(). See FitDateTimeExtension.getDate().
getTodayIndex() int
Retourns the day index throughout the week of the current day. See getDayIndex().
getWeekDates() List<int>
Retourns the day numbers of the current week, from monday to sunday. Ex: 26, 27, 28, 29, 30, 31, 1.