Class
GoogleWorkspaceChangeTracker
OfficeIMO.GoogleWorkspace.Sync
Consumes complete Drive change pages and advances each source token only after that source succeeds.
Inheritance
- object
- GoogleWorkspaceChangeTracker
Constructors
public GoogleWorkspaceChangeTracker(GoogleWorkspaceSession session, GoogleDriveClientOptions? options = null) #Creates a tracker using the supplied session and optional Drive client settings.
Parameters
- session OfficeIMO.GoogleWorkspace.GoogleWorkspaceSession
- options OfficeIMO.GoogleWorkspace.Drive.GoogleDriveClientOptions? = null
Methods
public void Dispose() #Disposes the underlying Drive client without taking ownership of the session.
public async Task<GoogleWorkspaceSyncCheckpoint> InitializeAsync(IEnumerable<string>? sharedDriveIds = null, CancellationToken cancellationToken = default) #Obtains current start tokens for the user feed and distinct supplied shared drives.
Parameters
- sharedDriveIds System.Collections.Generic.IEnumerable<string>? = null
- cancellationToken System.Threading.CancellationToken = default
Returns
Task<GoogleWorkspaceSyncCheckpoint>public async Task<GoogleWorkspaceChangeReadResult> ReadAsync(GoogleWorkspaceSyncCheckpoint checkpoint, GoogleWorkspaceChangeReadOptions? options = null, CancellationToken cancellationToken = default) #Reads each feed to its new start token without advancing a failed source in the returned checkpoint.
Parameters
- checkpoint OfficeIMO.GoogleWorkspace.Sync.GoogleWorkspaceSyncCheckpoint
- options OfficeIMO.GoogleWorkspace.Sync.GoogleWorkspaceChangeReadOptions? = null
- cancellationToken System.Threading.CancellationToken = default
Returns
Task<GoogleWorkspaceChangeReadResult>