using Umbraco.Cms.Core.Models; namespace Umbraco.Cms.Infrastructure.HybridCache.Persistence; internal interface IDatabaseCacheRepository { Task DeleteContentItemAsync(int id); Task GetContentSourceAsync(int id, bool preview = false); Task GetMediaSourceAsync(int id); IEnumerable GetContentByContentTypeKey(IEnumerable keys); /// /// Refreshes the nucache database row for the given cache node /> /// /// A representing the asynchronous operation. Task RefreshContentAsync(ContentCacheNode contentCacheNode, PublishedState publishedState); /// /// Refreshes the nucache database row for the given cache node /> /// /// A representing the asynchronous operation. Task RefreshMediaAsync(ContentCacheNode contentCacheNode); /// /// Rebuilds the caches for content, media and/or members based on the content type ids specified /// /// /// If not null will process content for the matching content types, if empty will process all /// content /// /// /// If not null will process content for the matching media types, if empty will process all /// media /// /// /// If not null will process content for the matching members types, if empty will process all /// members /// void Rebuild( IReadOnlyCollection? contentTypeIds = null, IReadOnlyCollection? mediaTypeIds = null, IReadOnlyCollection? memberTypeIds = null); /// /// Verifies the content cache by asserting that every document should have a corresponding row for edited properties and if published, /// may have a corresponding row for published properties /// bool VerifyContentDbCache(); /// /// Rebuilds the caches for content, media and/or members based on the content type ids specified /// bool VerifyMediaDbCache(); }