using System.Collections.Generic; using Jellyfin.Plugin.JRay.Models; namespace Jellyfin.Plugin.JRay.Services.Interfaces; /// /// Stores the prioritise/ignore rules that shape the work-discovery API /// (GET /Plugins/JRay/Tasks/Pending). Rules can target a genre, a /// series, or a single item; more specific scopes override broader ones. /// public interface IMediaPolicyStore { /// /// Gets all currently configured rules. /// /// The list of rules (a copy; safe to enumerate). IReadOnlyList GetRules(); /// /// Adds or replaces the rule for a given scope+value. If a rule already /// exists for the same scope and value, its action and label are updated, /// so a target can never hold two conflicting actions. /// /// The rule to set. void SetRule(MediaPolicyRule rule); /// /// Removes the rule matching the given scope and value, if present. /// /// The scope of the rule to remove. /// The value of the rule to remove. /// true if a rule was removed. bool RemoveRule(PolicyScope scope, string value); }