public void Init(EventPaging progress) { EventPaging existing = EventTypePaging.Where(et => et.Type.Equals(progress.Type, StringComparison.OrdinalIgnoreCase)).FirstOrDefault(); if (existing is null) { EventTypePaging.Add(progress); } }
public void MarkEventTypeProgress(EventPaging progress) { EventPaging existing = EventTypePaging.Where(et => et.Type.Equals(progress.Type, StringComparison.OrdinalIgnoreCase)).FirstOrDefault(); if (existing is null) { EventTypePaging.Add(progress); } else { existing.PaginationToken = progress.PaginationToken; existing.ProcessedCount = progress.ProcessedCount; existing.TotalCount = progress.TotalCount; } }