ExtraRule.cs 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. #pragma warning disable CS1591
  2. using MediaBrowser.Model.Entities;
  3. using MediaType = Emby.Naming.Common.MediaType;
  4. namespace Emby.Naming.Video
  5. {
  6. /// <summary>
  7. /// A rule used to match a file path with an <see cref="MediaBrowser.Model.Entities.ExtraType"/>.
  8. /// </summary>
  9. public class ExtraRule
  10. {
  11. public ExtraRule(ExtraType extraType, ExtraRuleType ruleType, string token, MediaType mediaType)
  12. {
  13. Token = token;
  14. ExtraType = extraType;
  15. RuleType = ruleType;
  16. MediaType = mediaType;
  17. }
  18. /// <summary>
  19. /// Gets or sets the token to use for matching against the file path.
  20. /// </summary>
  21. public string Token { get; set; }
  22. /// <summary>
  23. /// Gets or sets the type of the extra to return when matched.
  24. /// </summary>
  25. public ExtraType ExtraType { get; set; }
  26. /// <summary>
  27. /// Gets or sets the type of the rule.
  28. /// </summary>
  29. public ExtraRuleType RuleType { get; set; }
  30. /// <summary>
  31. /// Gets or sets the type of the media to return when matched.
  32. /// </summary>
  33. public MediaType MediaType { get; set; }
  34. }
  35. }