< Summary - Jellyfin

Information
Class: MediaBrowser.Model.Dto.BaseItemPerson
Assembly: MediaBrowser.Model
File(s): /srv/git/jellyfin/MediaBrowser.Model/Dto/BaseItemPerson.cs
Line coverage
0%
Covered lines: 0
Uncovered lines: 1
Coverable lines: 1
Total lines: 58
Line coverage: 0%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Coverage history

Coverage history 0 25 50 75 100

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
get_HasPrimaryImage()100%210%

File(s)

/srv/git/jellyfin/MediaBrowser.Model/Dto/BaseItemPerson.cs

#LineLine coverage
 1#nullable disable
 2using System;
 3using System.Collections.Generic;
 4using System.Text.Json.Serialization;
 5using Jellyfin.Data.Enums;
 6using MediaBrowser.Model.Entities;
 7
 8namespace MediaBrowser.Model.Dto
 9{
 10    /// <summary>
 11    /// This is used by the api to get information about a Person within a BaseItem.
 12    /// </summary>
 13    public class BaseItemPerson
 14    {
 15        /// <summary>
 16        /// Gets or sets the name.
 17        /// </summary>
 18        /// <value>The name.</value>
 19        public string Name { get; set; }
 20
 21        /// <summary>
 22        /// Gets or sets the identifier.
 23        /// </summary>
 24        /// <value>The identifier.</value>
 25        public Guid Id { get; set; }
 26
 27        /// <summary>
 28        /// Gets or sets the role.
 29        /// </summary>
 30        /// <value>The role.</value>
 31        public string Role { get; set; }
 32
 33        /// <summary>
 34        /// Gets or sets the type.
 35        /// </summary>
 36        /// <value>The type.</value>
 37        public PersonKind Type { get; set; }
 38
 39        /// <summary>
 40        /// Gets or sets the primary image tag.
 41        /// </summary>
 42        /// <value>The primary image tag.</value>
 43        public string PrimaryImageTag { get; set; }
 44
 45        /// <summary>
 46        /// Gets or sets the primary image blurhash.
 47        /// </summary>
 48        /// <value>The primary image blurhash.</value>
 49        public Dictionary<ImageType, Dictionary<string, string>> ImageBlurHashes { get; set; }
 50
 51        /// <summary>
 52        /// Gets a value indicating whether this instance has primary image.
 53        /// </summary>
 54        /// <value><c>true</c> if this instance has primary image; otherwise, <c>false</c>.</value>
 55        [JsonIgnore]
 056        public bool HasPrimaryImage => PrimaryImageTag is not null;
 57    }
 58}

Methods/Properties

get_HasPrimaryImage()