diff options
| author | Shadowghost <Ghost_of_Stone@web.de> | 2026-05-24 18:26:21 +0200 |
|---|---|---|
| committer | Shadowghost <Ghost_of_Stone@web.de> | 2026-05-24 18:26:21 +0200 |
| commit | cb9d6e9884d3b952321736392801743198b0ccd9 (patch) | |
| tree | 20d5c3e533f1447ceb0d1c6413d831f075702828 /MediaBrowser.Controller/Persistence/IPeopleRepository.cs | |
| parent | 11758461200c7b369dd23db5ac7c9f232a87cf21 (diff) | |
Add batch method for people names
Diffstat (limited to 'MediaBrowser.Controller/Persistence/IPeopleRepository.cs')
| -rw-r--r-- | MediaBrowser.Controller/Persistence/IPeopleRepository.cs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/MediaBrowser.Controller/Persistence/IPeopleRepository.cs b/MediaBrowser.Controller/Persistence/IPeopleRepository.cs index a89f3ef9ee..3a3b2bfb1f 100644 --- a/MediaBrowser.Controller/Persistence/IPeopleRepository.cs +++ b/MediaBrowser.Controller/Persistence/IPeopleRepository.cs @@ -32,4 +32,14 @@ public interface IPeopleRepository /// <param name="filter">The query.</param> /// <returns>The list of people names matching the filter.</returns> IReadOnlyList<string> GetPeopleNames(InternalPeopleQuery filter); + + /// <summary> + /// Gets the people names per item for a batch of item IDs, preserving per-item list order. + /// One database round-trip for the whole batch; grouped by item id in memory. + /// Items with no people are omitted from the returned dictionary. + /// </summary> + /// <param name="itemIds">The item IDs to get people for.</param> + /// <param name="personTypes">Optional person types to include (e.g. "Actor", "Director"). Empty for all.</param> + /// <returns>Dictionary keyed by item id; values are the per-item people names.</returns> + IReadOnlyDictionary<Guid, IReadOnlyList<string>> GetPeopleNamesByItem(IReadOnlyList<Guid> itemIds, IReadOnlyList<string> personTypes); } |
