SyncService class
Gerencia todo o ciclo de vida da sincronização de dados, incluindo operações automáticas em background, tratamento de falhas, modo offline e recuperação de erros.
- Implemented types
Constructors
- SyncService.new(ISyncConnectivityService _connectivityService, ILoggerProvider _syncLogger, ISyncErrorManager _errorManager, ISyncErrorReporter _errorReporter)
- Gerencia todo o ciclo de vida da sincronização de dados, incluindo operações automáticas em background, tratamento de falhas, modo offline e recuperação de erros.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
-
isOnline
→ ValueNotifier<
bool> -
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
syncData
→ ValueNotifier<
SyncData> -
final
Methods
-
addToSyncQueue(
{required String entityType, required String entityId, required SyncOperation operation, required Map< String, dynamic> data, bool isFileToUpload = false}) → Future<void> -
override
-
canContinueWithoutSync(
) → Future< bool> -
override
-
clearCorruptedData(
) → Future< void> -
override
-
dispose(
) → void -
override
-
enterOfflineMode(
) → Future< void> -
override
-
forceSync(
{bool isManualCall = true}) → Future< void> -
override
-
getPendingItemsCount(
) → Future< int> -
override
-
isBackgroundSyncActive(
) → Future< bool> -
override
-
logCreate(
{required String entityType, required String entityId, required Map< String, dynamic> data, bool isFileToUpload = false}) → Future<void> -
Registra log de criação de entidade
override
-
logCustomOperation(
{required String entityType, required String entityId, required SyncOperation operation, required Map< String, dynamic> data, bool isFileToUpload = false}) → Future<void> -
Registra operação customizada
override
-
logDelete(
{required String entityType, required String entityId, required Map< String, dynamic> data}) → Future<void> -
Registra log de exclusão de entidade
override
-
logUpdate(
{required String entityType, required String entityId, required Map< String, dynamic> data, bool isFileToUpload = false}) → Future<void> -
Registra log de atualização de entidade
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
resetSyncState(
) → Future< void> -
override
-
startBackgroundSync(
) → Future< void> -
override
-
startSync(
) → Future< void> -
override
-
stopBackgroundSync(
) → Future< void> -
override
-
stopSync(
) → Future< void> -
override
-
toString(
) → String -
A string representation of this object.
inherited
-
triggerImmediateBackgroundSync(
) → Future< void> -
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited